July 2007 Linux Adventure<?php include( $_SERVER["DOCUMENT_ROOT"] . "/includes/foot.txt");Surrounded by linux books and texts and cds... well virtual books, html text (including a wealthy legacy from my previous adventures and my "crow imitation" see a linux doc/download grab it! instinct.
More seriously Gordon from PG's Knoppix 4.0.1 CD has showed me the holy grail - what LINUX should aspire to (since the Rescue CD and Damn Small Linux both failed on my old toshiba, only Win98se and Knoppix 2 (init level 2, text only))
I did manage to download and finally use (because I had heard about parted years ago - partitions without defragmenting!) partimage which creates a compressed image of a hard drive (well it's just sectors and zip/tar!)
After moving all the files from the 266 Mhz 32MB RAM 4GB HD toshiba Beast onto the work's IBM thinkpad (1.2 Ghz!) I was ready for my tests (or trial by fire, again).
The things to remember when using linux are command line! knoppix 2 or any way to get to the command line is best, honestly the drivers for graphics cards aren't up to snuff (and laptop designers don't make it any easier).
The good thing to remember is that command line has multiple prompts (tty1 - 4) as long as you hit alt-f1 or alt-f2.
I'm more comfortable with man,ls,cd .., and the crazy file structure: /,/dev/listed device drivers,/mnt/actually mounted devices (which I get to name!), /bin for binaries, /sbin for more binaries
And I still remember about mount -t auto /dev/sda1 /mnt/sda1 for mounting my portable usb drives (which are dirt cheap for 512 MB). I even vaguely remember swapon and swapoff and all that...I've learned a great deal about gparted (the gui version which seems pretty easy) and as I said, partimage has some basic documentation and that's all you need. I backed up 4 GB to 300+ MB (well ok, 810 MB data to a 320 MB file on the afore- mentioned cheap USB memory, but in 30 minutes!) and I even made some changes and restored it in 20 mins... and it still worked.
Most of this adventure started when I accidentally locked out the new used IBM thinkpad laptop - disconnect it from a domain without the local admin password... but I learned of a great tool - chntpwd or something like that, which basically accesses the SAM (user list), system (hardware list), and security (syskey with encryption) and decrypts the whole thing, and can even write to NTFS (which officially KNoppix does not support).
So after using that tool (command line and very hacker ish) I got the fever.
Actually, before that I used Gordon's gift of Knoppix 4.0.1 LiveCD and a patient half hour/ full hour from Gordon walking through it I managed to save Armand's data from his dying hard drive workstation with knoppix and throw the files over the network using Samba to his other winxp desktop. Yeah, I was impressed!
My preparations were thorough, basically reading and trying everything. With a backup (see partimage success) and linux having matured quite nicely (support for old laptops, usb, etc.) I felt confident in finally installing linux and windows on a hard drive (again).
I even had some free days (pre work/school) where I sat down with a linux book and learned a bit about vi and command line programming with gcc. Programming in C really pushed me to learn more about the operating system, the fundamental underlying nature of computers (and hardware) and linux is a natural progression in that. gcc -c filename or something like that... I even found (and kind of like) tcc, tiny c compiler which either does tcc -c filename.c (and creates filename.o which then needs tcc -o filename.exe filename.o because you can combine multi .o's together in one .exe) or just simply tcc -o filename.exe filename.c As long as you have all the libraries in the include folder on the same level as tcc.exe it's quite easy to use the command line (easier even!). I also use notepad2 for text editing, mostly for the line numbers (but pretty colors are nice, remember the good old days with borland...)
I hate how long it takes for a swap file to be created - I've almost given up and gotten ready to hard restart... And it's really crappy that the text runs off the screen and I have to use the 'clear' command to get things under control.
So it's a work in progress... knoppix 2 (because none of the other options really seem to work), but I have knoppix 5.1.1 which does nifty things like wait for slower usb hardware, auto dma loading, etc. (Although without swap and 32MB with shared for video it doesn't have enough to run.)
The free command shows me how much memory (knoppix takes 7 MB!) and I had to agree to the auto set up swap on sda (aka the usb which gets treated like a scsi by linux) so I'm ready for parted /dev/hda1 (interactive) Did I mention that parted without the parameter tries to load the currently running knoppix file system... unsuccessfully.
I look forward to painless "print" to see what's what, and then resize 1 0 2000 to make my windows parition 2 GB smaller. (Room for a linux or two). the 1 stands for MINOR which logically means the partition (why it's MINOR, something to do with HardDrive hardware), 0 is the starting point, 2000 is the ending point.
Last time, without swap, it ran out of memory (imagine that) and tried to kill unnecessary processes... eventually ended up killing parted :) No damage to windows though!
This time it took 3 minutes, beautiful. Now let's see... print again shows me a partition taking up 4 GB, not good.
So it hung at boot time, but everything has been ferryboated onto the thinkpad and I just have to format everything, repartition it (fat32 and ext3 and swap), install windows first, and go from there.
(Note: Linux is making me lose sleep.)
Ok, so parted and fdisk couldn't really agree on much. I used fdisk to delete all the partitions but parted seemed to want to take forever to create a 2 GB fat32 partition, was it out of memory?
Instead I finally broke down (and was lucky) and used my spare floppy which happened to be a win98se boot disk. Fdisk did manage to get the partition up quickly and formatted (oh, it only takes 1 MB, knoppix super recovery = 700 MB of compressed 2 GB). Partition(s) was the windows 2GB fat32 for my win98se (which will be optimized to the hilt).
I also left the other half empty for linux... which I have diligently learned should be at least 3 parititions, root (boot/system), home (user stuff), and swap.
Just getting windows back up is a pain but at least I have a working operating system - Knoppix (not just a silly win98se install cd - of course I do have the win98se install files - only 100+ MB, what did MS put on all those CD's?)
After getting the partitioning right I booted (Knoppix run level 2) and copied the win98se files into the empty c:\ drive and then used my boot disk (life saver!) to run setup.exe ... 30 minutes of boredom later win98se (sans all drivers which makes it's existence almost meaningless).
So getting the drivers for even the usb reader/card has to be done via knoppix (why didn't I think of that earlier?) and I'm still scratching my ... head trying to remember where those oh so common Toshiba laptop from 10 years ago drivers are...
NOTE: at school (Victoria College for English with Mr. Wang as my MCSE instructor) I'm working on getting a lightweight, compatible with a dell 1450 wireless usb, wine for windows apps, livecd so we can have a couple more kick around computers for the afternoon "I need internet and email and chat" rush. Most likely that will be Adventures part 3.
Further important notes (from Rute guide) alt-f1 through alt-f6 are text consoles alt-f7 should be the default gui console in gui mode you'll need ctrl-al-f# to access the ttys ctrl-pgup/pgdwn lets you scroll the console free is how much mem is free df is how much disk space dircmp is comparing directories du
gives a directory's space usage dmesg prints all messages during the bootup process file prints the type of data in a file head first 10 lines of the file tail last 10 lines of the file primary partition = only 1? extended should cover the rest of the drive?
installing linux (knoppix) via livecd
first you have to create empty space (not even a partition)
ideally you have a single hd per os really you have windows (must be first partition) and linux
windows should sit in one big partition (because that's MS efficiency, program files needs windows registry needs...)
make sure you back up your data and your MasterBootRecord (data backup can be done via livecd, knoppix eh?, with partimage but you'll need a second hd or a big usb, 50% compression is considered great!)
?>