Friday, November 12, 2010

It just doesn't work

Every time when I want to use find or grep in bash shell, it just doesn't work. Not even after I check the man page. I have to find examples online eventually. It's kinda weird. I'm not trying to make full use of them. The most simple function would suit me just fine. I always get the sequence of the arguments wrong or miss some controller. Sometimes, you have to write it down to memorize something. That's what I'm trying to do. Here are the examples of these two commands.

find files: find -iname '*' ./*(path) -r(search subdirs)

find text within files: grep -i(ignore cases) *(patterns to search) ./*(path) -r(search subdirs)

Labels:

Tuesday, November 09, 2010

Virtual Disk Expansion

In the other day, a problem popped out when I wanted to upgrade the system. It said that the disk space is not enough although i already set the disk to expansible. The successful solution is doing it from inside the system. I used GParted iso to boot the virtual machine instead of the hard disk and expanded the partition. After that, upgrade could be done using system application. 

However, there were two problems after the upgrade. First one is described in the previous post. The other one I encountered today is that it said no swap space available in the system monitor application. I guess it caused by changing the partition information expanding the disk. Here is the solution.

  • Check the UUID of swap partition in /etc/fstab
  • Check the UUID of /dev/disk/by-uuid
  • Compare the UUIDs between the two locations
  • Write the right one in fstab and reboot.

Labels: , ,

Monday, November 08, 2010

Guest Additions for VirtualBox

After several upgrade process, the Kubuntu system won't install guest additions properly until I tried this.

1 load VBoxGuestAdditions.iso in VirtualBox

2 start the guest system (Kubuntu)

3 run these commands

bash$ sudo mount /dev/sr0 -t iso9660 -r /cdrom
bash$ cd /cdrom
bash$ sudo ./VBoxLinuxAdditions-x86.run

4 reboot the guest system