Archive for the ‘Windows’ Category

In the past four months I have revisited Ubuntu Linux, and I have to say, I like it! During my three month trip to South Africa I ran Ubuntu in VirtualBox, and also installed it on my computer in Wubi. Hopefully content written during the trip will be posted soon. During the trip I got a hold of Ubuntu 9 and installed it through Wubi on my computer, with mixed results. Now that I’m home though, I have partitioned my new 750 GB hard drive and am now running both Ubuntu and Windows 7.

So first, Wubi. Wubi is the Windows-based Ubuntu Installer that allows you to install Wubi almost as you would a normal program. The Wubi option allows you to boot into Ubuntu as you do Windows, and works pretty well, almost as well as a native installation. Almost. The only real problem I had with my Wubi installation of Ubuntu was that there was no Hibernate feature.

In a Wubi installation of Ubuntu, through some conflict with a virtual hard disk format or something, there is no hibernation option. Hibernate is by far the most used mode on my computer, although this being a problem is really just personal preference. The other thing that really is a problem, not really a personal preference thing like the last one, is that while running Windows, you have absolutely no access to the files on your Wubi installation. None, no access. That means if I need to get a picture or document from my Wubi installation, I would have had to restart my computer, boot into Ubuntu, and either move that file to a removable storage device, or to a folder on my Windows hard drive. Problematic.

Despite that fact, in case you’re interested in installing Ubuntu using Wubi, here’s what you need to do:

  1. Go to Ubuntu.com and download an ISO of Ubuntu, or, if you have an EXTREMELY slow internet connection and have lots of time, go ahead and request a disk with Ubuntu to be sent to you. A quick note to those of you who don’t know what an ISO is: An ISO is technically an image, although not in the conventional sense of a picture. An ISO is an ‘archive’, or an image of every single file on, typically, a hard drive. Having an ISO file solves the problem of getting software that needs to be run from a CD to masses of people. By utilizing an ISO file, it is possible to put all the files in the archive on a disk, and this recreate the disk needed. In this case, the Ubuntu ISO contains all the files required for installing and running Ubuntu, put conveniently into a single file that can be burned to a disk to use in installation.
  2. Once you have an Ubuntu ISO, which is the option most of the readers here will take, go ahead and download and install DAEMON Tools Lite. DT Lite allows you to mount .ISO, .MDX, and various other .ISO-like file types as if they were actually burnt to a CD in your CD-Rom drive. For those of you that don’t want an explanation of this, skip ahead to step 3. Here’s what I mean: Typically an ISO is meant to be downloaded and burnt to a CD (Or DVD) so that a perfect replica of that CD, DVD, or Blu-Ray disk, can be had by anyone that obtains a copy of that ISO file. As you might have guessed, this can be used to even make illegal copies of the install disks for operating systems like Windows (XP, Vista, 7), programs like Microsoft Office, and yes, even OS X. More popularly, you can use the .ISO format and formats similar to it (.MDX is my preferred for this sort of thing) to make backups of your DVDs using DT Lite. As done with the .ISO file distributed on the Ubuntu.com website, you can make copies of DVDs and share them, thus effectively pirating DVDs in a very easy way.
    Now the common denominator in all these forms mentions above is that you need a CD, a DVD, or in an extreme case a Blu-Ray disk (CD’s hold up to 700MB of data, DVDs can hold up to around 8.5GB on Dual-Layer disk, and Blu-Ray disks, the last time I checked, could hold around 25GB) to use the .ISO file (or .MDX file, for that matter) in order to effectively utilize the files inside the archives. Otherwise, all you can do with that backup copy of your favorite movie is burn it to a DVD and watch it from there. Now here comes DT Lite. DT Lite mounts an archive file (ISO, MDX, etc), which makes the computer think that the file being mounted is actually burnt to a CD or DVD and is spinning in your disk drive right now. So if you make a copy of your DVDs, and of course, I mean the ones you own, not the ones from Netflix, you can mount that file in DT Lite and watch the DVD as if you had popped the DVD into your computer. Same with ISO files, which is the easiest way to install Ubuntu with Wubi.
  3. Now that you have downloaded and installed DT Lite onto your computer, go ahead and open it. I generally ignore the main window and look for the taskbar icon, because that had just been easier for me in the past. Right-click the taskbar icon and click ‘Mount’n’Drive Manager’. As a side note, to create copies of CDs and DVDs click ‘Disk Imaging’ instead. DT Lite will scan your disk drives for media to create an archive of, and ask you where you would like to save it. If you would like to save the archive in a format other than the default .mdx file type, browse for a new file location and change the file type it is to be saved as in the drop-down menu at the bottom of the explorer window.
  4. On the far left side there should be a button with a disk and a green + sign on it. Click that button and navigate to the saved Ubuntu ISO file. Once found, double-click the ISO file. This will open the ISO file in the Mount’n’Drive Manager.
  5. Now click the image of a disk with a play sign on it. If you’re unsure of the button, hover over the active buttons until you see one that says ‘Mount’. Click it.
  6. Auto-Play should popup asking you what you would like to do with the ‘newly inserted disk’. In Windows 7 at least, I cannot speak for other versions, you should be able to simply click the link that says ‘Run Wubi Installer’, or something to that effect. Otherwise open up (My) Computer, and double-click the disk drive that holds the Ubuntu ISO. It should have a similar name to the actual Ubuntu ISO archive you downloaded. Once you double-click the disk drive, you should be presented with an option to ‘Run Wubi Installer’, or again, something to that effect. If even that fails, click once on the drive, and then look for the ‘(Run) Autoplay’ button somewhere towards the top of the Explorer window.
    One of those should get the Wubi installer running!
  7. Now all you need to do is follow  the on-screen prompts. The only problem you may have when installing Wubi is lack of disk space, but so long as you have around 10GB free, give or take, you should be fine. Note, if detailed instructions are needed here, I will post a manual with pictures.

I also ran Ubuntu, the same version I had installed on my computer by Wubi, in VirtualBox. For those of you that do not know, VirtualBox allows the installation of various operating systems on your computer in a virtual environment. This means that although someone may be viewing this page in Windows right now, they could open up VirtualBox, start up a distro of Linux that has been installed there, and run that operating system inside of Windows, without needing to restart their computer and boot into that operating system. I used this on my hard drive so that when I was booted into Windows 7, as I usually am, I could easily open Ubuntu to program in, as programming in Ubuntu is far easier than Windows due to all the convenient built-in tools available.

So now that you’re interested, how does VirtualBox work? VirtualBox works by creating a virtual hard drive on your computer. This is a file, which you specify the size of, that all the files installed in your operating system are stored on. Basically, this is setting a portion of your hard drive off for this installation, and telling VirtualBox to store all the files there. Once your operating system has a ‘hard drive’ to install on, VirtualBox will install that operating system on it.

So how about a step-by-step guide:

  1. Download and install VirtualBox at http://www.virtualbox.org/wiki/Downloads. Make sure to download the correct version for your operating system. Once the download is complete, double-click the executable file to open it.
  2. Follow the on screen prompts and install VirtualBox with the default settings, unless you’re sure that you want to change something. You’ll probably be asked to install some drivers or something quite a few times. Agree to them all. Once the installation is finished, click Finish and start up VirtualBox.
  3. Since this is a new installation, you don’t have any existing installations in VirtualBox. So long as you have the ISO of the operating system you would like to install in VirtualBox, go agead and click the button labeled ‘New’. Click ‘Next’ when prompted.
  4. In this screen you will be naming your VirtualBox installation, and telling VirtualBox what kind of operating system you are installing. Pick a descriptive name that you will be able to differentiate from your other VirtualBox installations. The first drop-down menu allows you to choose what kind of operating system you will be installing. If in doubt, you’re probably installing a version of Linux, and if you don’t know otherwise, it’s probably safe to go with that option, or ‘Other’. If you select Linux from the ‘Operating System’ menu though, you will have quite a few option to choose from in the ‘Version’ menu, so it would be a good idea to check through that list before hitting ‘Other’. For this example, I will assume that you’re installing Ubuntu Linux, and have chosen ‘Linux’ for the operating system, and ‘Ubuntu’ for the version. Click next when you’re finished.
  5. In this screen you will be asked to choose how much RAM, commonly referred to as ‘memory’, that will be allocated to your VirtalBox operating system.
    -For all of your confused as to why RAM was renamed memory and are wondering what you’re supposed to call your hard drive space now, I am with you! I usually refer to RAM as what it is, RAM, and my hard drive space as hard drive space. I guess I’m just old-fashioned in that manner. Keep the distinction in mind though.
    Here it would be a good idea to just check to see what the minimum system requirements for the operating system you are installing are, so that you don’t end up grossly underestimating how much memory you actually need, and end up with a very sluggish machine. Head over to Google and do a quick Google search for that info, and then enter that amount, plus a little more if you have some to spare, in the box on the right-hand side. Click Next.
  6. Here you will choose whether to create new virtual hard drive, or use an existing one. You will need to choose to create a new one; this option should already be checked. Click Next.
  7. Now you will find yourself in the ‘Create New Virtual Disk Wizard’. In this wizard you must choose how much of your hard drive space you would like to allocate to this VirtualBox machine. Again, head over go Google and check the minimum system requirements for the operating system you are installing before proceeding, and enter that number, plus a little more if it can be spared. Click ‘Next’ until you find yourself at the screen titles ‘Hard Disk Storage Type’.
  8. The wizard does a fine job in describing the differences between a dynamically expanding storage or a fixed storage drive, so I will leave the choice up to you. However, I will say that I would choose ‘Fixed-size Storage’ based on personal preference. This way I can’t use up all my hard drive space unknowingly and not be able to access any of the files that are taking up all that space through Windows. Once you have made your choice, click ‘Next’.
  9. Here you must set the size of your virtual hard drive. Use the system minimum, plus a few more GB if you can spare the space. Ultimately, how much extra space you allocate is your call, but I usually go for two or three GB depending on how much I plan to use this virtual machine. You can also change the location of the virtual hard drive, which is simply a single file, if you need to, but I usually just leave it alone. Click ‘Next’ when finished.
  10. You should now be presented with the ‘Summary’ screen. Skim over the summary and make sure you like all the settings. If you are satisfied, click ‘Finish’.
  11. Eventually you will need to click ‘Finish’ again, so click it. Now you will be back where you started 8 steps ago, except your new virtual machine should be in the window on the left side. Make sure it is selected, and click ‘Start’ at the top of the window.
  12. Welcome to the First Run! Just cancel the wizard. You will be told that there is no bootable device -blah blah blah. Click ‘Devices’, mouseover CD/DVD Devices, and click ‘Choose a virtual CD/DVD disk file…’. Navigate to the folder where you’ve stored the ISO and select it. Now click ‘Machine’ and scroll down to ‘Reset’ and click it. The window should refresh and boot into the setup for the operating system. The installation from here on out will differ from operating system to operating system, so check for a guide for that particular operating system. As far as VirtualBox setup goes, you’re finished. Whenever you would like to run the virtual machine, open up VirtuabBox and make sure the machine you want to start is selected, and then click ‘Start’.

Some of the definite pluses for me to run Ubuntu in a VirtualBox machine included easy access to an easy place to do programming without having to restart my computer, a place to try Ubuntu hassle and risk free, and by having Ubuntu installed in a virtual machine I could do pretty much anything with it and if something messed up, clear off the virtual hard drive and start over. This made a lot of things easier for me. For beginners wanting to test out Ubuntu, or various other distros of Linux, I would strongly recommend this before partitioning your hard drive and installing that distro natively. Similarly, I would recommend this especially to programmers. Ubuntu is a great place to program because it natively supports so many programming languages, and while the editors can be somewhat basic at the beginning, it is extremely easy to get editors as complex as you need them to be. I, for one, am perfectly happy with gedit. gedit offers syntax highlighting, and automatically senses which programming language I’m using and highlights accordingly. I don’t need anything more fancy than that. Seriously though, I would highly recommend this.

So those are two ways to install Ubuntu on your computer without having to partition your hard drive or do anything quite that drastic, but what if you want access to your files in Windows? Both Wubi and an installation of VirtualBox wont allow you to access any of the files stored on their ‘hard drives’ unless you are booted into the Wubi installation of Ubuntu or have VirtualBox open.

Well, to my knowledge, the only other option is to partition your hard drive. Sounds scary, doesn’t it? Is it really scary? No. I recently, for Christmas, got a 750 GB replacement hard drive for my computer. I have been planning on reinstalling Windows 7 since I got home from South Africa a little less than a month ago, and I finally did on my new hard drive. Since the hard drive had no existing operating system, I used the ‘Custom’ installation option to install Windows 7 on my empty hard drive, which also gives me the option to create and format hard drive partitions. At first, I was planning on simply using my Windows installation disk to create the partitions on my new computer: a partition for my Windows 7 installation as well as the program files, another partition for all my personal files, and one more partiton for Ubuntu. Or at least, that’s what I had planned.

The idea here was to create a seperate partition for my operating system installations, and have my personal files stored seperately. In doing this, I would no longer need to backup my computer before reinstalling Windows, and totally wiping my Windows installation would no longer be such a big deal. With my documents stored seperately all I needed to do was overwrite the partiton that stored my Windows 7 installation, and voila, I had a clean installation of Windows 7.

But what if you aren’t planning on doing a clean install of Windows, and thus wont be using the Windows partition manager anytime soon? My first recommendation would be to simply boot from the Ubuntu CD and use the built-in partition manager. To do this follow the instructions below:

  1. Download the Ubuntu ISO from Ubuntu.com. Make sure you download the right one – 32bit or 64bit.
  2. Assuming that you are running Windows 7, find the ISO file in Windows Explorer and right-click it. Click ‘Burn to Disk’. If you don’t see that option in the context menu look for it in the blue bar running at the top of the screen. Follow the on-screen prompts.
  3. Once the burn is complete, leave the disk in your optical drive and restart your computer.
  4. When given the option, press the F12 key, which will bring up a list of devices you can boot from. Note that the key you must press to bring up the screen to choose which device to boot from will vary from computer to computer, but generally it is the F12 key. When the Boot Options screen comes up, use the arrow keys to scroll between the options until you can choose to boot from the CD/DVD drive. Hit the Enter key.
  5. Now your computer should boot from the Ubuntu disk. You will be given the option to try Ubuntu, or to install. I would recommend trying Ubuntu. If you were to choose the install option you would be required to install Ubuntu, and do nothing but that. Conversely, were you to choose to try Ubuntu you will not only be able to install Ubuntu as you would by choosing the install Ubuntu option, but depending on your wireless card you may also have internet access, where you will be able to read this tutorial for reference, and occupy yourself throughout the installation.
  6. The Ubuntu desktop should appear a few moments after you click the Try Ubuntu button. Click the ‘Install’ icon on the desktop.

My recommendation is EASEUS Partition Master Home Edition (free). After my clean installation of Windows 7 I used this program to modify and create the required partitions for my Ubuntu installation. For this tutorial, I will assume that you are using EASEUS Partition Master Home Edition.

  1. Once you’ve downloaded Partition Master open it up.
  2. As a side note, make sure that your already created partitions have enough space to expand in case you need to make them bigger. I forgot to do this, so now all my partitions are a set size, and the only one I can expand now is my Windows partition, which is where I store only my Windows 7 installation, and my program files. All my personal files are stored separately. Because the Windows partition is 50GB, I doubt I’ll need to expand it any time soon. Now how much extra space you set aside for each partition depends first on how much hard drive space you have open on your computer, and second on what the partition in question will contain. For example, my 50GB Windows partition will most likely not need to expand so long as I keep my personal files on a separate partition. Therefor, I would leave little if any extra space for my Windows partition. Conversely, it would make sense to leave space for my Documents partition to expand as I needed it to because that is where I store all my documents for both my Windows 7 installation and my Ubuntu installation.
    On my 750GB hard drive, I would set aside between 5GB and 15GB to expand my Ubuntu partition (for files or programs that must run or be located on an ext2 formatted drive, respectively). For my Documents partition, the space would vary. I currently have a 200GB partition for my personal files, to wiggle room of about 50GB would be plenty.  Additionally, if you know that you will be installing programs requiring large amounts of hard drive space for program files, create a ‘wiggle’ partition of a size according to your best estimate depending on the program. The disk partitioning strategies outlined above are optional. However, I would strongly recommend adding a small partition between your Windows partition, or whatever type of partition is at the end, and your Ubuntu partitions. Also, the information coming is extremely important if you are planning on expanding partitions at any time:
    In order to create a ‘wiggle’ partition that is effective, the ‘wiggle’ partition MUST be beside the partition it is responsible for, and preferably on the right side of that partition. Generally you can expand a partition in either direction only dependent on the location of the unallocated space, but in some cases partitions can only be expanded to the right of their current location. As another side note, you CANNOT move a partition, regardless of its placement.
  3. Now that EPMHE (EASEUS Partition Master Home Edition) is open, you should see a screen similar to the screenshot below:
    Disk 1 is generally your primary drive (normally C:). Any other hard drives, flash drives, external hard drives, or similar drives, will be located below your primary hard drive. Unless you have a second hard drive in your computer you will want to be modifying your primary hard drive, which is, again, normally Disk 1.  Click on the gray box labeled ‘Unallocated’. Next, at the top of the screen click the button with the green plus sign labeled ‘Create’. Label the drive ‘Ubuntu System Files’ or something to that effect. This partition should be about 5GB or so and will include all your Ubuntu system files. Although not needed, you can make the partition larger if you feel like it. On my computer, for example, the partition is set to be 10GB, minus formatting space. Note: When resizing the drive to 5 (or 10) GB, either type the number in the text box beside the ‘Partition Size:’ label, or if you are going to drag the slider to choose a size, drag the RIGHT side. Now choose a drive letter, anything will do, and for the file system, choose ‘EXT2’ from the drop-down menu. By choosing EXT2 you for an Ubuntu partition file system, you will be able to access it in Windows very easily. Click ‘OK’. You have now created a partition for your Ubuntu system files.
    Next, you need to create a swap partition. The swap partition acts like additional RAM for your Ubuntu installation, and should be about the size of your built-in RAM. Follow the same steps you used to create the last partition and label the drive ‘Ubuntu Swap’ or something like that. The file system should be EXT2. Again, the size should be equivalent to the size of your built in memory, or RAM. Once finished, click ‘OK’.
    Next, you need to click on the gray box labeled ‘Unallocated’ again. Click the ‘Create’ button and label the drive ‘Ubuntu Home Files’ or something similar. Choose a drive letter, and again format the drive as EXT2. Now this drive, as you may have guessed form the drive label you gave it, will be holding your personal files that need to be located on an Ubuntu file system. If you plan on having most of your files on a seperate ‘Documents’ partition, then this need only be about 10GB or so, which is the recommended minimum size by Ubuntu.com. Choose a drive size, and click ‘OK’.
    These are the partitions you will need to install Ubuntu. I recommend you create them in this order, because now you have the option to expand your Ubuntu home partition without disrupting any other files. Click ‘Apply’
    Take note of the exact sizes of each drive you will be using in Ubuntu in MB, because during the Ubuntu installation you will not be presented with drive labels or anything of that sort, just something like /dev/sda1 and a drive size in MB.
  4. Now that you have all the partitions ready and formatted, click ‘Apply’ and wait for EPMHE to make the necessary changes. This will require a reboot, which if perfect. Slip your Ubuntu disk into the disk drive before the computer reboots or during if you think you are quick enough. When prompted, hit the ‘F12’ key to open your boot manager. Alternately, you could download a program such as OSL2000, which is a boot manager requiring no human input to start, but it is easier to just hit the F12 key when prompted.
  5. When a list of available boot devices comes up, use the arrow keys to scroll down to the entry labeled CD/DVD Drive and hit enter.
  6. Ubuntu will boot up. You may have to hit the Enter key once more at a welcome screen asking if you would like to 1) try Ubuntu or 2) Install Ubuntu 3)…. If you do, make sure you select ‘Start (Try) Ubuntu’ and hit Enter. This will load the desktop, and may give you access to the internet during installation depending on your wireless card, or if you are using a LAN cable at the time.
  7. There should be an icon on the top left of the Ubuntu desktop with the title ‘Install Ubuntu’ or something to that effect. Double-click it. The Ubuntu installation wizard will popup and start prompting you for input. Here you will enter your username, password if you choose one, blah blah blah, time zone, blah blah blah, and finally come to the screen asking where you would like to install Ubuntu.
  8. Now I’m guessing that you are going to want to install Ubuntu and keep Windows on your machine. If that is NOT the case, select the radio button labeled ‘Use entire hard drive’ or ‘Use entire disk’. Otherwise, click the radio button labeled ‘Manual’ or ‘Specify Partitions Manually (advanced)’ or something similar. Click ‘Forward’.
  9. The window presented to you now should have a bar across the top, colored in sections in various colors. These are the partitions on your computer. Below is a window with all of the partitions that you can select, format, and install on. Look for the partition you made for the SWAP area. Once found, format it as EXT2 and set the mount-point to ‘/swap’. Click ‘OK’.
    Find the partition you made for the Ubuntu system files, and click it. Format it as EXT2 and set the mount-point to ‘/root’ and click ‘OK’.
    Finally, find the partition you made to be your home directory and format it as EXT2. Set the mount-point on this drive to ‘home’ and click ‘OK’. Now go back to the partition with the mount-point as ‘/root’ and click is. Cancel the formatting window if it comes up. Click the ‘Install’ button at the bottom of the window.

The only thing you may need to do now, if you did not do it before specifying the partitions to install on, would be setting your time zone, and setting your keyboard layout.  Unless you know for sure differently, choose the US Standart keyboard layout. Presently, Ubuntu will ask to restart. Restart your computer.

The next thing you should see if the GNU Grub boot loaded with a few different options. The bottom option should be your Windows installation, and will be labeled as such, but the currently selected option should be your installation of Ubuntu. Unless you need to boot into Windows for something, hit Enter and check out your new Ubuntu installation. Otherwise, use the arrow keys to move up and down the list to the Windows option and hit Enter to boot into it.

Currently, Ubuntu is the default operating system. If you are anything like me, you will want Windows to be the default. But how to change this? It is not done by changing anything on the Grub boot screen. Boot into Ubuntu and then follow the next steps. Note, there will be a paragraph or two at the end of this next part explaining what each of these commands does, and how to use it in case you would like to know.

Changing the Grub bootloader default operating system:

  1. At the top of your screen, on the left side, a menu is labeled ‘Applications’. Click it. Hover over ‘Accessories’, then move your mouse down the new menu and click ‘Terminal’. Do not be afraid.
  2. Type the following into the terminal and hit Enter:
    cd ../../boot/grub
  3. Congratulations, you have changed your directory in Ubuntu via the command line. If you would like to see a listing of all the files in this or any directory, type in: ls and hit Enter. Now you need to type in the following and hit Enter once more:
    sudo gedit grub.cfg
    After hitting Enter, you will be prompted to type in your password. Type it in and hit Enter once more. Note, you will not see your password as you type. This is normal.
    A text editor named ‘gedit’ should popup with a bunch of text in it. This is the Grub bootloader configuration file.
  4. Look for the that reads something like this:
    set default=”1″
    It should be on line 13 or somewhere near that. Change the ‘1’ to a ‘6’. This variable, for that is what default is, sets the default operating system to run. The number ‘6’ may not be the correct number for you. If, when you restart, Ubuntu is still selected as the default operating system to load or you did not receive the desired result, count the number of entries in the Grub bootloader. Subtract 1 from that number, and that is the number you need to set default to.
  5. Click the ‘Save’ button, or hit ‘Ctrl+S’ and exit gedit. If you would like to make sure that your changes were saved, go back to the terminal and type in the following and hit Enter:
    cat grub.cfg
    Use the scroll wheel to move up the page until you see default being set. Make sure it is the number you desired. If not, repeat steps 3-5.
  6. If you are ready to reboot and try this out, type in ‘exit’ and hit Enter. This will close the terminal. Next click the menu titled ‘System’ near the ‘Applications’ menu and click ‘Shutdown’. You will be asked if you want to Shutdown, Restart, Suspend, or Hibernate. Click Restart. Next time Grub loads, Windows should be selected. There is an automatic timer on the Grub bootloader that will launch the default operating system if nothing changes during 10 seconds, so you can just start your computer and leave it.

Basic shell commands:

cd: The first command used in the above example was cd. cd stands for ‘Change Directory’, and it is used to change your current directory in the shell. To change to a directory, type in cd followed by the name of the folder that you would like to cd in to.
.. is a command used in conjunction with cd that tells cd to change to the directory above the current directory. As an example, take the cd command used above:
cd ../../boot/grub
First we tell the shell that we want to change the current directory. Next, the place we want to go is passed in. ../../ means  that we would like to go up two levels. So if you were in the folder ‘l3’ with a structure similar to the one described below, you would now be in ‘l1’:

l1
l2
l3

However, if the folder name was ‘l 3’ (l space 3) then you would either need to enclose the directory in quotes: “l 3” or use the continuation character to negate the space: ‘l\ 3’. To really grasp this, experiment some. Messing up when changing directories will create no system problems, so you can mess up all you like.

gedit: gedit is a very versatile text editor for Ubuntu Linux. By typing gedit followed by the name of a file, you can open an new text file in the current directory with the name specified. If the name specified already exists, the existing file will be opened.

When creating a file in this way, by using the command gedit new_file_name , the terminal will become unusable until the gedit window is closed. Once you close the gedit window, the terminal will once again become usable. To remedy this inconvenience append the and sign (&) to the end of the line. So the new command would look like this:
gedit new_file_name&
This will leave the terminal active during the time you are using gedit, and is especially helpful when programming because now you only need one terminal window open to work on and test programs.

sudo was appended to the command gedit this time so that gedit could be run with administrator privileges  and save the system file ‘grub.cfg’. To run any program or command with administrator privileges, just append sudo to the beginning of the command.

ls: ls is an extremely useful command that displays the file and directory names of everything in the current directory. Since ls just displays the filenames, what if you want more detailed information? Both ls -lsa and ll will list all the names of the files in the current directory along with the group they belong to, the read/write/execute permissions, and the date last modified.

The last partition you need to create is a swap partition. The swap partition acts like additional RAM for your Ubuntu installation, and should be about the size of your built-in RAM. Follow the same steps you used to create the last two partitions and label the drive ‘Ubuntu Swap’ or something like that. Again, the size should be equivalent to the size of your built in memory, or RAM. Once finished, click ‘OK’.

A Channeler is a program I would like to see. Yes, I channeler. What is a channeler? well in the context that I am thinking of it in, it would be a program that would channel my internet connection to one specific application. For instance, instead of my internet connection being divvied up between all my open applications that require an internet to even preform the most mundane task, this program would let me choose which programs would be allowed to use the internet. No more would Firefox be using my internet connection to refresh my email while I was playing Combat Arms, no more would Evernote be syncing my notes with their server. No more would windows be checking for updates in the background. I want a program that will do that. I want to be able to give one program all the resources [in this case, the internet connection] that it needs to do its task most quickly and efficiently.

That is what I would like to see.

Hello peoples, and happy newyears to all!

As anyone who read my post Windows 7 will know, I got a new computer for Christmas. Those of you who slacked off and didn’t read it, now you know.

The first thing I did with my new computer was to reinstall the operating system. For those of you who aren’t familiar with this practice, this is done to remove all the software that the manufacturers install on it. All that software that you don’t receive reinstall disks for. This took much less time than I was expecting, as I’ve only done this before on a Windows XP machine. Within 20-30 minutes it was finished and I was checking out my new desktop.

Now if you haven’t read my post Windows 7 by now, go read it. Right now.

Go.

Now that you’ve gone and come again, I’ll move on.

Since you’ve read my post Windows 7 you’ll know all the main features of Windows 7 that I really like, the aesthetics, how it works, the mixer- and many many more features. This isn’t going to be a reiteration if that article, I just want to say that for all the crap Microsoft took with Vista, this operating system could be their savior. Who knows? Maybe they decided to use all their expieremental ideas to create an operating system that they were guessing would fail, then learn from the mistakes and create the super OS that is Windows 7? Who know? More likely Vista was just a failure, but either way, Windows 7 is the best thing that’s happened to PC users since Windows XP.

Just wanted to make my opinion clear on that.

I hope everyone has had a Merry Christmas, and I hope you all have a happy Year.

Now with the  seasonal formalities out of the way I will proceed with my article.

I received a new Dell INSPIRON 15 laptop for Christmas, and that’s been what I’ve been doing for the past couple days. My new computer came with Windows 7 Home Premium, 3 GB of RAM, Intel Core 2 Duo processor, and about 230 GB of hard drive space. An upgrade in every way from my older Dell INSPIRON 9300 laptop in almost every way. Now here’s what I wish my new laptop had that my old laptop had:

  1. My old laptop had three lights at the top by the power button. A light for the Caps Lock, Num Lock, and Scroll Lock. My new laptop doesn’t have these lights, so I don’t know whether or not I have Caps Lock on until I start to type. Something that can be very very annoying.
  2. The Screen Size. My old laptop had a 17 inch screen, and it was very tall. My new laptop has a 15.3 inch screen size, and is not as deep as my old laptop screen.
  3. The USB ports. My old laptop had 6 USB ports, arranged with two on the sides, and four in the back. My new laptop has three USB ports. Two on the left side, and one on the right. Because of how the USB ports are arranged, it is difficult to have more than two USB devices attached to my computer at once. To combat this problem I bought a USB extender. Now I have 6 available USB ports.
  4. The power jack is on the side. I’m not really sure if this should be a plus of a minus. I would say it’s a minus because it requires my laptop to have more space to the left side where the jack is. It would be a plus though because it is much easier to plug my power cord in to my laptop now. Before I had to close the screen and bend over my laptop to find the power jack, not something that’s fun to do. Now all I have to do is plug it in to the side.
  5. The D-USB port (I believe that is what it is called), the port that connects my laptop to an external monitor, is on the left side by the power jack. I usually have my external monitor on the right side of my computer, so this is pretty inconvenient.

Now here’s what I like about my new laptop:

  1. Although the screen size is smaller, I do like this because it will be easier to travel with, and also with I’m sitting in my airplane seat it will fit much better.
  2. The microphone and the headphone jacks are in the front. On my old laptop they were on the left side, and because of its width, this made it difficult in an airplane seat.
  3. Because my screen is smaller, and because of how my new computer is built, it is much lighter than my old computer.
  4. The operating system. Sure, Windows XP was fine, but once you’ve used Windows 7 you’ll wonder how you ever made it with Windows XP. I’m not saying that Windows XP is bad, no, I’m just saying that Windows 7 is better. Some of my favorite features of Windows 7 are as follows:
  • Aero. I really like the transparency of Windows 7; it makes the operating system look so much cleaner and more advanced.
  • Automatic background shuffling. In Windows 7 you can set your background to change after a certain amount of time without the need for a special program.
  • When you mouseover a window or group of windows you will be presented with a little larger than normal thumbndails of the pages that that particular program has open. If you were to mouseover one of these windows, it would pop up as if you had clicked to open it. This is just a preview of what it would look like if you were to open it up. You can then click on one of the larger-than-normal-thumbnails to open the window.
  • If you grab a window and drag it so that your mouse pointer is to the left side of your screen, a frame of that window will expand to half the screen size. If you were to let your window go there, it would fill half of your screen. You can do this with either side of your screen. This is very helpful if you want to compare two documents or move files between folders. If you were to drag your window so that your mouse pointer was at the top of your screen a frame would expand to fill your whole screen. Letting go of that window would make the window maximize. You can also grab the top or bottom and drag it up or down to the bottom or top of your screen. If you do this then you window will expand to reach the top and bottom of the screen. Handy for reading long documents.
  • If you shake a window, all windows but that one will be minimized.
  • Windows no longer include the application name along with the icon, but just the icon. This saves a lot of space on my taskbar: I haven’t filled up my taskbar yet!
  • Shutting down your computer. If you shut down your computer and you still have a program running, Windows will ask you if you still want to shut down your computer, or if you want to cancel the shutdown.
  • Start menu. I love the new start menu! Besides the icon being smaller, and cooler looking, which is a bug plus, the start menu is much improved from previous versions. The front panel is still populated with your most recently used programs, that hasn’t changed, but something about the icons has. Some icons have a small arrow to the right side of them. If you were to click on the arrow for the, say, Microsoft Word icon, you would be presented with your most recent documents from that application.
  • You can pin items to your taskbar, as usual, but now if you right-click on them you will be presented with a list of recently opened windows. For example, if I were to right-click the Windows Explorer icon I would be presented with my Recent Folders, a list of folders that I have used recently. This is very, very handy when tracking down a folder.
  • The second part of these taskbar icons that I really really like is that you can pin a location to them. If, for example, I used my Downloads folder a lot, then I could pin that location to my Explorer icon. So whenever I right-click the Windows Explorer icon I will be presented with the list of my recently opened folder locations, along with whatever locations I’ve pinned there. Here’s an image to illustrate that point. Notice that the folder ‘downloads’ is under the Pinned section.

    The same goes for iTunes. If I play a song from iTunes, it gets added to the Recently Played list which I can view by right-clicking the iTunes icon. I can also pin songs to that menu so that whenever I right-click iTunes I will have the option to play that song.
    Here’s an image of what this would look like:
    And if I were to mouseover one of these song names a small push-pin would appear to the right of the song name. Clicking that push-pin would pin that sond permanently to the right-click menu for the iTunes shortcut.
  • In Max OS X if you move your mouse to the right side of the screen your desktop will appear. Or at least, I think that’s how it works. Anyway, somehow you can have a shortcut to get to your desktop. Windows 7 also has two features like this. The first one, and my favorite, is when using the Alt+Tab shortcut to switch between windows, an option to view the desktop is included. Here’s a picture to see what that looks like:
  • The other shortcut to the desktop is to move your mouse over to the lower right hand side of your screen. There is a small unlabeled button there. If you hover your mouse over it, a preview of your desktop will appear. If you click it, all windows will be minimized and the desktop will show. Here’s a picture showing this:
    Note, this is a picture of what it looks like when I mouseover the button, not when I click it. The frames on the page are outlines of my active windows.
  • Another thing I really like about Windows 7, as I have mentioned before, is the start menu. But not only the start menu, but the search/run dialog box. In windows this button didn’t do much. It ran some programs, and opened a folder location if it was feeling up to it. Otherwise, nothing. Windows 7’s version is so much better. I can type something in to the box, and it immediately starts searching for something matching that name, whether it be file, folder or program. You can also type commands into this box and it will run. For example, I can either type in MSCONFIG and then find the application in the search results, or I can just run it as I would in Windows XP.
  • The new Disk Cleanup utility makes it much much easier to clean out old system files. In Windows XP you would have had to navigate through sub-menus and multiple tabs, but here all you have to do is click ‘Clean System Files’ and Disk Cleanup will add those files to the list of files to be cleaned.
  • In Windows XP when you click All Programs, or mouseover it, a very wide of very long menu expands with a list of all your programs, and some extra folders. In Windows 7 this is not so. In Windows 7 when you click All Programs, the start menu doesn’t get bigger, nor does it get smaller. All that changes is the spot where the most used programs were sitting. Now that spot is populated with a list of folders. That’s it. This makes it much quicker, more aesthetically pleasing, and more functional.
  • Another thing I like about Windows 7 is the games. In previous versions of Windows there wasn’t much in the way of Games. Windows 7 includes all the old games, and adds of few of its own. Including Chess ad Mahjong.
  • This next one is a major like of mine. Probably one of my favorite new features of Windows 7 is the audio mixer. In Windows XP you could change the Wave, Volume, CD, blah blah blah – all unimportant settings. In Windows 7 this is taken to the next level. Take a look at a snapshot of this:
    With Windows 7’s mixer I can change the sound levels from different applications. So if I’m playing a game in Firefox with a stupid soundtrack, I can mute Firefox’s sound and only listen to the sound coming from iTunes. It’s a great little feature, also very helpful when playing games that require a lot of attention.
  • Sticky Notes. This was a big deal in BumpTop, and now Windows 7 has it. Check out this screen capture:
    If you expand this image you can see that I made a few example notes on my desktop. Very handy for quick things that you want to remember.
  • Connecting to a projector. In Windows XP if you wanted to have a second screen attached to your computer you would have to go to right-click on your desktop and navigate to Properties>Settings and then enable a second screen, and then place it wherever it was located. On my new computer all I have to do is push the screen button (which doubles as F1) and a box will pop up with a few options. Here’s a snapshot:

    Note that I get the option to have my screen set as Computer Only, Duplicate my screen over to my second screen, Extend my screen to my second monitor/projector, or just use the projector/screen only.
  • Paint. In Windows XP Paint is a pretty basic picture editor, and that hasn’t changed too much in Windows 7, so if you’re lo0king for a substitute to Photoshop or GIMP then look elsewhere. Paint for Windows 7 is actually pretty decent. It looks like they stripped down Word and took Paint and put it in there. Here’s what it looks like:
    Paint has always been a great light-weight picture editor, and now even more so with its overhaul.

Those are my favorite features of Windows 7 and my new computer. When I find some more I will be sure to post them. Unfortunately I will be putting off the computer maintainince article for awhile while I finish my review of Windows 7, and I have a new post in the works titles Recent Happenings Revision 3. It’s going to be a good article you can look forward to.

Later.

How to make your computer display the “Hello World!” message using the popular programming language Python. I will also introduce you to installing programs on your computer and how to create shortcuts to programs, folders, or even other shortcuts. Even if you never use the skills you are about to learn for the rest of your life you will still benefit from an insight into the mindset that every programmer uses every day to accomplish this and many other programmaticall tasks every day.

The first thing you would need to do is download the Python programming language from python.org. The install is simple, but could get complicated, so I will walk you through it. Go to python.org and download the Python installer which will be in the form of an .exe file. Once your download of the installer is finished, double-click it to start the install. A dialog box will pop-up with an open file security warning: click Run. The first screen you will see is one asking you to decide whether to install Python for all users, or to install it for just yourself. I recommend that you select the option to install Python for just your user because it will make the install quicker, and take up less hard drive space. After this decision all you will have to do is click ‘Next’ until the install is finished. By continuing to click ‘Next’ you will install Python with all the default settings for your user, which is perfectly fine.

With python installed on your computer you could start programming, but there’s one more thing that you can do to make it easier once you start writing your program. Right-click on your desktop and navigate to the ‘New’ submenu. Once there click on ‘Shortcut’ to create a new shortcut on your desktop. A window should pop up asking you to decide where the shortcut should look to run a program. In that dialog box you can either type in or copy-and-paste the following text: C:/python26/lib/idlelib/idle.bat and click ‘Next’. Now you can name your icon whatever you wish in this dialog box. I suggest just clicking the Next button without changing the name, as the default name for this shortcut will be sufficient for our purposes. This shortcut you just created will now make it much easier for you to quickly create and debug your Python programs. I cannot make this next point clear enough: debugging your python programs is very important. If you don’t debug often you can have many problems and not know about it until you have hundreds, or even thousands of lines of code. Once you’ve got more than 50 lines of code, debugging becomes much more complicated than if you had just done it systematically. Double-click the shortcut you just finished creating. Doing this will open a window that looks similar to Notepad as far as visual simplicity, but that is where the similarities end. This new window is called the Python IDLE: you will create and debug all of your Python programs in this window.

Congratulations, you have finished the hardest part!  Now it is time for you to start your first program! All python programs must start with what is called the ‘shebang’ statement, followed by the location to your python installation. The ‘shebang’ statement is important because it tells the computer that this file is a python file, which changes how the computer handles the file. Programmers, when referring to the shebang statement usually imply that the path to your python install is included in the actual shebang statement. In your case, your shebang statement, along with the path to your Python install will look like this:
#!/usr/bin/python
The red text is the actual shebang statement, which, again, tells the computer that this file is indeed a python file. The ‘shebang’ is then followed by the location that Python is installed on your computer in the UNIX format denoted by the green text. This will start all of your programs: if you do not have the shebang then your programs will fail.

Since you now have the shebang statement in your program you will want to create a variable. A variable is a name or string of names concatenated with underscores (_) that represents a numerical formation such as 12345678910, or a string. A String can be grouping of characters such as “Python is cool” or “I like programming in python,” Or a string could be a number formation, or just one number or letter. Strings are denoted by encasing the intended contents of the string within double or single quotes as we did above. For example, Python is cool could not be a string in Python because it does not have double quotes: “Python is cool” is a valid string, however, because it includes double quotes. Another example of a string could be “1234”, or “123abc”. As you can see, a string can contain letters, numbers, or a mix of both. For your first variable let’s call it my_first_var and make it a string. Notice that we use underscores to attach the words in our first variable ‘my’, ’first,’ and ‘var’. This is because no programming language can read spaces. When declaring variables spaces are a problem and are going to be dealt with through an error message. You will also have noticed that instead of writing my_first_variable we wrote my_first_var That is because ‘var’ is short for Variable, so we can use those two interchangeably and still know what we’re talking about. In all programming languages to define what a variable is equal to, what it is representing, you must use the equals (=) sign with your number or string on the other side of the equal sign. For our purposes, we will define my_first_var to “Hello, World! This is my first string in python!” To do this you will need to write the following code on a separate line from your Shebang statement:
my_first_var = “Hello, World! This is my first string in python!”
Congratulations! You have no created your first string with Python! Notice that we used my_first_var­ concatenated with underscores, an equal sign to show what the variable was equal to or representing, and double quotation marks to encase our string.

It is always a good idea to run your programs periodically so that you can be sure that none of the changes you’ve made or additions you have added in are going to make the program fail. Now would be a great time to run your new program and make sure that you have gotten all your Python code correct. To do this push the ‘F5’ key located above the number ‘5’ key. If you haven’t saved your program yet, Python will ask you to save your program before continuing. Save your program to an easy-to-remember spot such as your Desktop, and then run your program again. When you get around to running your new program nothing should appear in the new window that pops up. This is because we have not told the program to display, or ‘print’, anything to the screen. If something did appear to the screen, there is a problem with your program and you should go back and make sure it is all typed in correctly.

Our next step in our programming journey is going to be to print our newly defined variable my_first_var to the screen. Printing our variable to the screen will not print “my_first_var”; rather, printing my_first_var will print “Hello, World! This is my first string in python!” because my_first_var is just a placeholder for the string it is assigned to through the equals sign. To go about printing your variable to the screen you must use the ‘print’ statement. Create a new line under the line where you define my_first_var and type in the following code:
print my_first_var
Save your program and run it again by pushing the F5 button. You should see
“Hello, World! This is my first string in python!” appear in the command line window that pops up onto your screen.

Congratulations, you have successfully completed your first program using python! Not only have you learned how to start Python programs, but you have also learned how to create and print variables containing strings and numbers. You have also learned more about how to use your computer by installing programs and creating shortcuts to virtually anywhere on your computer.

First, let me add a few more key phrases here so that I can get the most views here. This solution will be the easiest way to find the ID’s of Firefox elements.

Find the XUL element ID’s of Firefox elements.
Finding the element ID’s for Firefox.

1. If you’ve followed my instructions in my last post, open your Firefox profile that does NOT use WebScarab as a proxy.
2. Go to addons.mozilla.org and download Firebug. Firebug allows you to easily view the contents of webpages, and change them in real time. Once you’ve installed this addon, restart Firefox.
3. Now that that is done, open the following URL in a new tab: chrome://browser/content/browser.xul

You should see an exact replica of your Firefox interface now in the browsing window. Pretty cool, huh? Now that you have the Firefox Interface in a window where you can easily view it, you may go through it with Firebug. The easiest way to do this is to use the ‘Inspect’ button, which allows you to hover over an element, Firebug scrolling to that part in the ‘web page’. So suppposing that I wanted to know the ID for the search bar. I would click the ‘Inspect’ button, then I would hover over the scrollbar. Once I’d done this, Firebug would scroll to a line in the code which would tell me that the ID for the url container is ‘url_container’, and the actual URL bar is called the ‘urlbar’. Pretty simple.

Now sometimes just hovering over an item wont quite cut it. Sometimes you will be forced to go through the code manually. To make this easy, open Firebug in a separate window so that you have the most space possible.

Once you’ve located an element through Firebug, you have two options. One! You can change the CSS attributes in real time to see what would happen. If you do this, no changes you make will remain in place.
You’re second option! You could find the userChrome.css file, which controls the CSS for your version of Firefox. The best way to do this is to just search for it with Windows search or something similar.

Once you’ve found userChrome.css, I recommend opening it it HTML-Kit, my favorite Web Developing program. If you don’t have HTML-Kit, and don’t plan on getting it, you can just open it in a simple text editor.
Armed with your new knowledge of the ID’s that go into Firefox, you may now change different aspects of your browser! Here’s a small example using the urlbar.

So I’ve opened userChrome.css in HTML-Kit, and it’s a blank document. That’s fine. To change the background color of the urlbar, I’m going to type in the following:

#urlbar
{
background-color: orange !important;
}

Those of you familiar with CSS will know that the pound sign (#) denotes that ‘urlbar’ is an ID, that ‘background-color: orange’ changes the background color from it’s default to orange. Now the ‘!important’ may be something new to you though. To add any elements to userChrome.css and have them overwrite Firefox’s built in style sheet, you MUST add the ‘!important’ after the actual value.

So now you know how to find the ID’s of all of Firefox’s elements. You can now edit anything you would like: changing colors, fonts, positions-anything you can think of. If you are not familiar with CSS, check out w3cschools.org, or come back here. Soon I plan on having some basic CSS up here, along with the basics for Pythong programming.

Posted: August 27, 2009 in Apple, New Tech, Operating Systems, Trends, Windows
Tags: ,

Well it’s been awhile since I posted on here, I just really haven’t had anything to post about until now.

A few days ago I got my regular PC World Daily Tech News email, and the first news story caught my eye. Snow Leopard Is a Pale Imitation of Windows 7. Wow. I never thought that I would be hearing that.

I remember awhile ago when a lot of people were complaining that “Vista was a copy of the Mac OS”. Now the tables have turned, or at least, they’re trying, but all of the Mac fanboys and girls are trying to hold it right there. Check out some of the comments at the bottom of that article. I can almost see all of those people writing those comments from their Mac computers. I only went about half-way down the page, but all I read up to that point was slams against the author by Mac fanboys. And people say PC fanboys are bad, ha! This is ridiculous! I do have to agree with the author though. Apple is bringing new features to it’s operating system, but 64 bit? we’ve had that since Vista. If you would like to see the new features Snow Leopard is adding Head over to the Apple website. I have to say that I’m kinda disappointed in Apple this time though. I’m looking for something revolutionary. They give us “improved iChat”. Here I want you to all see a few comic strips I found awhile back.

gamespy001

This comic talks about games, but I think it can be related to general PC-Mac conversations also. Especially this one.

windowsvistaandmacbelow

This was an image I found awhile ago during the big debate about how Vista had “copied” some of OS X’s features. Now I’m not going to say that it’s the other way around now, I don’t think that Apple is copying any of Windows’ features, but I do think they are lagging a little behind in their features, and now are trying to catch up. This is exactly what happened with Vista. Windows lagged behind in an area, and when Microsoft tried to fix it they got branded for copying Apple’s design. Now that Apple is fallen behind and are trying to fix it, they are being branded as copying Windows. It’s a vicious cycle.

I would like to finish this post with a quote.

What we’ve had so far has all been nice-a kind of placeholder-but now the professionals are coming.

-Clay Shirky