Pages

Showing posts with label command line. Show all posts
Showing posts with label command line. Show all posts

June 7, 2014

Playing streaming Flash videos without Adobe Flash on Linux

Adobe Flash is still the norm for watching streaming videos on the Internet. There has been a great adoption of HTML5-based videos on YouTube; around 90% of the channels I subscribe to play just fine on my Ubuntu 14.04 LTS, Mozilla Firefox (without Flash plug-in) setup. But still, there are those 10% that don't (the includes you, NBA channel!).

The plug-in is installable via the flashplugin-installer package in Ubuntu 14.04 LTS. But since Adobe abandoned Linux some time ago, then I decided to shun Adobe from my Linux set-ups. In this post, I show how I watch YouTube videos on my Linux box.

November 7, 2013

Wireless Network Connection via CLI

For the past few years, I have been using my trusty D-Link DWA-125 wireless dongle on my PC to connect to a wireless network. I have written about how to connect to WiFi via the command line but that was for unsecured networks. Recently, I've been fumbling around with Debian and did a minimal netinstall (to build it up with a GUI desktop) -- sort of a "from scratch" installation, like how Arch Linux installation is done. Since netinstall without a desktop environment drops you off at the CLI on first boot, I needed to find a way to connect to a WiFi network without the use of GUI network managers.

November 1, 2013

USB Thumb Drives: Mounting, Unmounting and Re-mounting

One of my hobbies is Linux distribution hopping. If you don't know what that means, it's that I regularly browse DistroWatch for news about new Linux releases. If something catches my interest, then I download the ISO, try out its live session in VirtualBox, and then finally, if impressed, install it to one of the partitions in my PC. And if it's that good, then I use it as my main OS.

The medium I use most when creating the installation media is a USB thumb drive. It's usually a no-brainer; just plug-in the thumb drive and the OS does its thing and auto-mounts it. The next part involves unmounting the thumb drive so that I can use the dd command to write the ISO to the thumb drive. I don't use the right-click » "Unmount" via the File manager because I just like typing in the command line

    $ sudo umount /dev/sdb1

and unmounted goes my thumb drive. Now I can proceed with

    $ sudo dd if=/path/to/file.iso of=/dev/sdb bs=4M; sync

and after some time, it finishes and I know that the distributions installation media is freshly baked. But sometimes I want to check the contents of the USB thumb drive, so I usually pull-out the drive, put it back in again and let the OS auto-mount it. So I thought to myself, "Isn't there a way to mount the USB thumb drive via the command line after dd command finishes without me pulling out and plugging back in the drive?" Apparently there is. And the command, in Ubuntu, is udisks. And using it is easy, it's just

    $ udisks --mount /dev/sdb1

and the USB thumb drive is remounted. Apparently, this same command can also be used to unmount the USB thumb drive

    $ udisks --unmount /dev/sdb1

Note that there is no need for the sudo superpowers to use the command.

That's it! Hopefully this will be useful for somebody out there

October 14, 2012

Setting up a wireless nework connection via command line

Update: These commands only works for unsecured SSIDs, apparently (and obviously).

Having set up a working wireless connection to the network, it was time to get it connected. I decided to use the command line way to connect to the network.

[usr@host ~]$ su -
Password:
[usr@host ~]# ifconfig <interface> down
[usr@host ~]# dhclient -r <interface>
[usr@host ~]# ifconfig <interface> up
[usr@host ~]# iwconfig <interface> essid "<essid_in_quotes>"
[usr@host ~]# iwconfig <interface> mode Managed
[usr@host ~]# dhclient <interface>