Showing posts with label debian. Show all posts
Showing posts with label debian. Show all posts

Thursday, February 4, 2010

Windows 7 & Debian Dual Boot

Quite a long day today. My school is enrolled in MSDNAA, which is basically free software from Microsoft, which as a CS student I am entitled to. So I woke up this morning, checked my student e-mail and read the account activation letter I'd received from them, and followed the link to their site where I discovered a venerable treasure trove of Microsoft software. Granted I wouldn't use most of it to save my life (the Office '07 suite is just indescribably horrendous) but also available for download was Windows 7. Now my Desktop is running Win7 so I've used it and despite my obligatory scorn for all things Microsoft, I have to admit it's the best OS they've ever put out. It's certainly better than Vista (from which there is nowhere to go but up). It's more stable than XP, and (obviously) more updated. Let's face it, XP's felt antiquated for quite some time.

What bothered me though was that you were not able to just download the .iso. You had to download an 'installer' (windows format .exe of course) which would download the file for you. I can't think of any reason for this other than to restrict the downloads to people already running a Windows operating system. At this point it doesn't get them any more customers, it certainly doesn't make them lose any, so why limit the availability of the software all students enrolled in the MSDNAA are entitled to based upon their current operating system? That would be like an electrician refusing to work on your house after you've already payed him because the wiring was put in by another company. It is an absurd ideology and quite frankly I don't see how consumers can tolerate it to the point where Microsoft's stock is selling at almost $30 a share.

I did wind up getting their pseudo-installer to run in wine, and then burned the iso all without ever having to leave backtrack, but it was still an unnecessary annoyance... But I digress. With the new Windows 7 (x64) disk in hand, I set about wiping my laptop clean and installing Windows. It went of without a hitch and everything's working fine. A rather rare occurrence. That being said, I only spent about 20 minutes in the OS until I had accepted one license agreement too many which, in turn, drove me to download and burn a Debian disk (Lenny main x64). I have never had a Linux install give me this many problems.

Apparently the kernel that Debian 5 ships with doesn't play nice on this particular build. For a distribution so well-known for stability, I was rather surprised. After an install that seemed to go off without a hitch, when I would boot into Debian it would hang on several different items. After 20 minutes I gave up, boot wasn't happening. At first I thought the install disk was faulty so I MD5'd it and compared it to the MD5 on Debian's site: they were identical. After two more installs with the same result I logged onto the IRC channel to see if anyone else had ever experienced this. After spending some time in #debian, the nice folks there pointed me to backports.org, where I was able to obtain a newer version of the kernel that worked with my box. Aside from a few minor hiccups that were later ironed out, I was now able to boot properly. After booting into the OS, it took me a while to figure out that the reason apt wasn't working properly was because I didn't have the right repositories in my /etc/apt/sources.list. After adding them, I went about configuring the OS. The wireless card works out of the box, but the network manager did not, so after creating a shell script that would launch netapplet, and throwing it in /etc/init.d/ that problem too is rectified.

The result of the day? Laptop wiped, dual boot with Windows 7 x64 and Debian 5 Lenny x64. I originally wanted to do a multi-boot with those OS's and BSD as well, but it's 10:00 and after spending about 8 hours doing this I simply don't have the energy. Maybe tomorrow If I get around to finishing all the other tech-stuff I need to do.

Sunday, January 10, 2010

A whole 'nother level of geekdom.

Two days ago, me and two friends spent about 8 hours in my 15 degree garage "linuxing". Box A was a server running the new dual core atom 330, and Box B was an old Pentium IV box. We'll start with Box A:

Debian 5 Lenny (i386) was actually a breeze to install, except when we went to install grub it defaulted to hd(0) which was a compact flash card on the motherboard, removed that, reinstalled (just goes quicker) and it was up and running. Since it had no wireless card, I had previously saved several debian packages to a flash drive for installation (such as openssh-server) and installed them after I spent an hour trying to figure out how to mount the drive. I feel a bit foolish actually, I tried pretty much every argument and every configuration of 'mount', but the reason it was not working was simply because I didn't specify a partition. I typed 'mount /dev/sdb /media/Lexar' when I should have typed '/dev/sdb1'. Got that mounted, installed the openssh-server and openssh-blacklist packages, and powered down the box. Then I took it upstairs and plugged it into the router, configured /etc/networking/interfaces to auto connect to an ethernet connection and removed all the peripherals leaving the server on.

We went back to the garage to work on Box B, which was to become a dedicated bittorrent box, and simultaneously worked on the Debian Box off of my laptop via ssh. The Debian box was to become a CSS (Counter Strike Source) server, so we configured that using the following sequence of commands (obtained from this guide:):

$ mkdir srcds
$ cd srcds
$ wget http://www.cstrike-planet.com/dls/hldsupdatetool.bin (usb)
$ chmod +x hldsupdatetool.bin
$ ./hldsupdatetool.bin
$ chmod +x steam
$ ./steam -command update -game "Counter-Strike Source" -dir .
$ ./srcds_run -game cstrike -autoupdate +maxplayers 20 +map de_aztec > srcds.log 2>&1 &

We then ran the server and checked the logs. Everything seemingly went fine except three textures were missing from the map. It was at this point we gave up for the night so I am unsure as to whether it was that particular map, or if there is a deeper problem at hand. We'll figure it out eventually.

While configuring the Debian CSS dedi over ssh, we also worked on the bittorrent box, which contains a rather ingenious little integration of mine that uses an aim client to add .torrents to Vuze's queue. We installed Mint 8 on the box which took about a year and a half running off the live CD, then installed the latest version of Vuze from their website (version in repos is really outdated. Using Pidgin's autoaccept plugin, we configured an aim account running on Pidgin that would autoaccept file transfers from my friend's screen name and save them in ~/Uploads. Firstly the plugin must be enabled, then on the buddy list you must right click the screename you want to authorize then go to autoaccept and always allow. Next, we configured Vuze to automatically scan that directory (~/Uploads) every 60 seconds for new .torrents, copy them to ~/Torrents, and add them to it's queue. Finally we set both Pidgin and Vuze to launch at login (During Mint 8 install we opted to not require login, ergo when the power button is pressed you are taken to the desktop, not the login window) and voila!

I eventually want to get vnc working on the bittorrent box, as well as actually play a game of CSS on the server but yesterday I was just too tired and wound up laying in bed all day watching a Law and Order: SVU marathon. I'll eventually write up a more complete (with pictures) guide on how to get the Pidgin/Vuze integration too.