Tuesday, November 4, 2008

Going Wireless

So I have been on a bit of a "media server" kick lately. I don't know why, but I guess because I have a Playstation 3 just waiting to find a server, I figure I should try it out.


My first problem is that my openSUSE box is on the wired subnet while my PS3 is on the wireless one, which is a real problem for UPnP servers. A cardinal rule, I guess, is that both the client and the server must be on the same subnet. I would be willing to bet there is some kind of hackery I can do with routes or something that would make one see the other, but that is far beyond my meager network-fu. So if the mountain can't go to Mohamed, then Mohamed must go to the mountain.


I had been resisting getting wireless to work on Linux just because of all the headaches it seems to cause. I also go wired for the speed boost, as I do lots of high bandwidth video transmitting in my job as a video conferencing software geek. But I also did not want to run a wire across my office floor to the PS3, so the lesser and more temporary evil was to go "dual NIC" on the Linux box and use a basic no-name wireless USB device I picked up for $5 at Microcenter. So here's what I tried:



  • Plug in wireless USB device

  • Like I said, it is a nameless device. More than just that, it is a labelless one too, so I didn't even know what kind. So I do:

    $ lsusb
    Bus 007 Device 005: ID 0bda:8189 Realtek Semiconductor Corp. RTL8187B Wireless 802.11g 54Mbps Network Adapter
    Bus 007 Device 002: ID 05e3:0608 Genesys Logic, Inc. USB-2.0 4-Port HUB
    Bus 007 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 006 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 001 Device 068: ID 046d:c51a Logitech, Inc. MX Revolution/G7 Cordless Mouse
    Bus 001 Device 067: ID 0451:2046 Texas Instruments, Inc. TUSB2046 Hub
    Bus 001 Device 005: ID 06f2:0011 Emine Technology Co. KVM Switch Keyboard
    Bus 001 Device 003: ID 0451:2046 Texas Instruments, Inc. TUSB2046 Hub
    Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 005 Device 002: ID 0d8c:000c C-Media Electronics, Inc. Audio Adapter
    Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

    to find out that it is a Realtek 8787. So off to the Realtek site to download the latest Windows drivers.

  • download 8187B driver from Realtek site and unzip them.

  • install ndiswrapper and, because I'm lazy and like a nice GUI, I grabbed a KDE frontend for it - kndiswrapper. I run kndiswrapper, clicked "Install Driver", navigated to the WinXP folder for the Realtek driver and selected the .inf file.

  • Things got a little confusing here, so it became a bit of a click fest as I tried to figure out what to do next. You'll need to at least "Configure Device" and put in the information for it. Be sure to do the "save as" sic or you'll just keep typing in the same information. The "Mode of Operation" field was a mysterious drop down, as I don't know the difference between "Managed" and "Ad-hoc", but "Managed" was the way to go for me. The "ESSID" is the name of the wireless network and you can type it in or click the "ESSID-Scan" button to search for it. And you add your password, if any, at the bottom.

  • After setting it up, I unplugged the USB device and plugged it back in, and followed that by clicking "Reload List" in kndiswrapper, and I finally got an interface up and running:
    $ ifconfig
    eth0 Link encap:Ethernet HWaddr 00:1A:4D:84:47:8E
    inet addr:192.168.204.104 Bcast:192.168.204.255 Mask:255.255.255.0
    inet6 addr: fe80::21a:4dff:fe84:478e/64 Scope:Link
    UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
    RX packets:78780 errors:0 dropped:0 overruns:0 frame:0
    TX packets:70212 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:1000
    RX bytes:76434598 (72.8 Mb) TX bytes:9857603 (9.4 Mb)
    Interrupt:16

    lo Link encap:Local Loopback
    inet addr:127.0.0.1 Mask:255.0.0.0
    inet6 addr: ::1/128 Scope:Host
    UP LOOPBACK RUNNING MTU:16436 Metric:1
    RX packets:66 errors:0 dropped:0 overruns:0 frame:0
    TX packets:66 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:0
    RX bytes:4028 (3.9 Kb) TX bytes:4028 (3.9 Kb)

    wlan0 Link encap:Ethernet HWaddr 00:14:D1:38:36:72
    inet addr:192.168.205.102 Bcast:192.168.205.255 Mask:255.255.255.0
    inet6 addr: fe80::214:d1ff:fe38:3672/64 Scope:Link
    UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
    RX packets:2354 errors:0 dropped:0 overruns:0 frame:0
    TX packets:318 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:1000
    RX bytes:771674 (753.5 Kb) TX bytes:39411 (38.4 Kb)

    Woo hoo!



Of course, at this point all that meant was that I had a mulithomed (dual NIC) computer. Now it is time to serve up some music, so next we'll talk about Mediatomb.





No comments:

Post a Comment