A Black Desktop

After trying to replace Nautilus with Pcman File Manager, I somehow got this black desktop

It’s not possible to right click on the Desktop and changing the background by using System->Preference->Appearance would not help either.

As I learned later from a new Hollandish friend, nautilus failed to start and therefore the Desktop cannot start proberly. Now, I don’t know any better, all I know is as soon as I start nautilus back up using terminal, the Desktop appears like magic.

So the solution was simple Restart Nautilus. In fact, restarting nautilus can solve a lot of problem when something does not display correctly.

I finally gave up on PCman File Manager and decided to stick with nautilus after all.

Anyway, that’s it!

A Blank Desktop in Ubuntu

A few days ago, when I decided that my 5GB partition for Ubuntu is getting a bit too crowded with all kinds of applications, I uninstalled a bunch of software through synaptic. Well, one of them is Evolution. I freed about 1GB of hard drive space. However, disaster stroke, everything disappeared from my desktop. I saw nothing on my desktop, no menus, no icons, no panels and not even my beloved desktop background but a smooth orange background. I freaked out. After several restarts, things did not help at all.

I needed to get online for some help, and the only way to do that was to open Firefox. So I opened terminal -> Ctrl+Shift+T (Thank god for the shortcut, otherwise I’m dead). Typed in firefox, it opened firefox! nice. Now, this guy had a similar problem, and the solution seemed very simple. I posted it here.

Problem

After uninstalling several packages in Synaptic, the desktop just goes blank and there is nothing, not even icons or panels.

Solution

We need to reinstall ubuntu-desktop, this will reinstall all the default packages.

  1. Hold down Ctrl+Alt+F1
  2. Login
  3. Enter

    sudo apt-get install ubuntu-desktop

  4. After you are done, return to x-server by Alt+F7 or just restart.

Interestingly enough, if you would like to have packages installed in Kbuntu or other distribution, there you can do so with a similar process as above. The only thing different is it would be Kbuntu-desktop (or else) instead of Ubuntu-desktop. Check Synaptic.

Ok, that is it.

A Useful Handbook for Linux Commands

To continue my quest on learning more about basic linux commands, I stumbled over this page called The One Page Linux Manual that provides a pdf file of basic commands and explations that I really need to know. Check it out. I post this here mostly for personal reference in the future.

Linux Commands

I have been scouting around for some sort of tutorial on how to work with Linux Commands in terminal. I’m sure some of you guys are doing the same thing. I found this tutorial on LinuxCommand.org. A very simple and straight forward tutorial to learn Shells in Linux, navigations, and more. It’s not overwhelming for those who never touch Linux before (but do realize that it’s a steep learning curve.)

Learning the Shell

That is it for this post. Enjoy the tutorial.

Stop!!

When you execute something that you did not want to happen, the output just keeps going like crazy and you really want to stop it. For example, I enter locate a, the command will search for everything with the letter a, which means millions. I need to interrupt and stop the execution.

Stop an execution

To interrupt whatever is going on, use

Ctrl+c

This will stop everything. Use this command wisely, you don’t want to interrupt an installation as it will mess your files and directories up.

Who am I? Where am I? and Where are you?

I usually get lost when using the terminal. Because there is no address bar, I have no idea what directory I am in. To make matter worse, I use zsh shell and all it shows for what suppose to be something like /Desktop is only a %. So, I need to know where I am.

Who am I?

Just in case you get so lost in the terminal that you forget who you are, the command below will let you know the user is in control of the session, effective user id, hence, you. So, if you forget who you are (I hope not) enter:

whoami

So there you go, linux just tells you who you are!

Where am I?

So I have been cruising around in the terminal, then I forget where I am, which directory I’m in, so to find out where I am in linux, I would enter in the terminal.

pwd

I learned this from a friend, it means “Print Working Directory”, the output looks something like this

/home/ma65p

That is my current/working directory, that is where I am!

Where are you?

What if I need to locate a file in Ubuntu? For example, I need to find a file named “you.” I would use either one of the two command below

whereis <what>
locate <what>

So, If I want to know where “you” is, I would enter in the terminal

whereis you
or
locate you

This would tell me where “you” is.
Have fun messing around, you never know what you can find with these two commands.

Get Some Help With Linux Commands

There are two things (that I know of) you can do in Linux to get some help with the commands in the terminal.

Use man command

This gives you a manual page for your command. The syntax is

man <command>

For example, if I want to see the manual for cd command, I would enter

man cd

The out put would be everything I need to know about cd, what it is what it does, its options, who made it…

Once you are done with reading the manual, and you want to quit, hit

Esc or q

Use –help

When you try to execute a command in the wrong way, Linux usually suggest you to try –help. Do that, sometimes it works and what it gives you is similar to what the man command would give you. For example

sudo --help

The input above will give you all options available for sudo command without any explanation or lengthly credits and copy right statements. The output looks like this, short and to the point.

ma65p@ma65p-laptop:~$ sudo –help
sudo: please use single character options
usage: sudo -h | -K | -k | -L | -l | -V | -v
usage: sudo [-bEHPS] [-p prompt] [-u username|#uid] [VAR=value]
{-i | -s | }
usage: sudo -e [-S] [-p prompt] [-u username|#uid] file …

But if you enter

man sudo

then the output looks like this

SUDO() MAINTENANCE COMMANDS SUDO()

NAME
sudo, sudoedit – execute a command as another user

SYNOPSIS
sudo -h | -K | -k | -L | -l | -V | -v

sudo [-bEHPS] [-a auth_type] [-c class|-] [-p prompt] [-u username|#uid] [VAR=value] {-i | -s | command}

sudoedit [-S] [-a auth_type] [-c class|-] [-p prompt] [-u username|#uid] file …

DESCRIPTION
sudo allows a permitted user to execute a command as the superuser or another user, as specified in the sudoers file. The real and effective uid and gid are set to match those of the target user as specified in the passwd file and the group vector is initialized based on the group file (unless the -P option was specified). If the invoking user is root or if the target user is the same as the invoking user, no password is required. Otherwise, sudo requires that users authenticate themselves with a password by default (NOTE: in the default configuration this is the user’s password, not the root password). Once a user has been authenticated, a timestamp is updated and the user may then use sudo without a password for a short period of time (15 minutes unless overridden in sudoers).

When invoked as sudoedit, the -e option (described below), is implied.
Manual page sudo() line 1

Last words

I’m sure some of you have been using one or two Linux command regularly. For me, I use top and cd the most. There are many commands in Linux that are fun and useful. For instance, some of you might have know the fortune command that gives you random fortune and jokes, some of which are not too bad. Using terminal and command could be painful sometimes because there is no way we know all those commands in Linux, there are hundreds of them, and each have a dozen different options, one of which could be fatal to our system (and ourselves). The key to avoid a disaster is to know what we are doing, and linux offers some great help. No, not the Ubuntu forum, you have to wait for someone to answer. No, not google, what if your internet is not working?. The commands above will help you sometimes in the future and it is a great tool to learn what you are doing.

Install Thinkfree Office Suite on Ubuntu

I checked out the new Thinkfree website and their office suite, it’s awesome. Read my post about the Thinkfree suite. Thinkfree offers an offline version of the suite that will sync with the online version. This is pretty sweet and it works in Ubuntu. Below is the instruction. Pretty easy.

Install Thinkfree Office Suite

  1. Download the office suite at this page. Make sure you donwload the linux version, it would be a .sh file.
  2. Save the .bin file to your desktop
  3. Open terminal: Ctrl+Shift+T or Applications -> Accessories -> Terminal
  4. Navigate to your desktop

    cd ~/Desktop

  5. Make the .bin file executable.

    sudo chmod +x filename.bin

    Replace “filename” with the .bin file’s name.

    You can see this page for more info on how to make a file executable.

  6. Execute the file

    sudo ./filename.bin

    Replace “filename” with the .bin file’s name.

  7. A dialog window will pop up, follow the instruction to install. You can select the directory, quick launch, and shortcuts on Desktop. Just like in Windows. Click Finish at the end

You are done. Enjoy.

Thinkfree Office Suite On Ubuntu

I tried out Thinkfree about a year ago and just recently check back and it was a pleasant surprise. The website looks much more professional and the user interface for the online version is totally awesome. Best off all, Thinkfree offers an offline version that sync seamlessly with the online storage. I love it. This post will not be some kind of tutorial but only my opinion about the suit. Visit my tutorial on how to install ThinkFree office suit for instruction.

The Good Stuff

Easy Installation

Except the part that I need to extract the .bin file, everything seems very easy. After extracting the .bin file, a dialog pops up and guides me through the installation process. It looks just like windows with the EULA that we never care to read, the checkbox that we crave to check so we can hit on the Next button and move on with our lives. It even offers to create shortcuts on the Desktop. Sweet.

Pretty Looking Icon

Well, not that they have anything to do with productivity but Thinkfree was the first to put shortcuts (with icons) on my Ubuntu machine automatically. I did not have to do a thing except checking the check box during installation.

Thinkfree Manager

This manager allows me to see all of my documents. All of them! including powerpoints, docs and spreadsheets. It also let me login into my account, sync all my documents to the online office. Very convinient.

Fast!

There are two words that excites me the most: Fast and Free. Thinkfree is Free as entitled and it is very fast in Ubuntu, faster than Abiword and definitely faster than Open Office. It takes matter of milliseconds to open documents,

Easy to use

The interface is extremely like Microsoft Office 2003 with all standard fonts. Needless to say, this is going to be an easy transition.

Covert to pdf

Ok, this is extremely convinient for me when I need to send files to someone who does not have microsoft office. Moreover, I often email documents to myself and then download them at school, but all my school’s computers have Office 2007, which kind of screw my formats up. A pdf file is easy to open and the format is fixed. Well, again, I will not be able to modify the documents, which would suck big time when I see something is wrong with my paper. But, oh, Thinkfree has an online version too, all my docs are online. I can always get back online an pull them offline.

Wide Variety of Formats

Thinkfree accepts all documents format, including the annal docx, open office, and abiword and even HTML…. This is easier for me, no more conversions!!

The Not-So-Good Stuff

Low Storage

I am allowed to have 1GB of storage online which is a lot for storing documents but somehow, in this world of unlimited email storage (Yahoo mail), unlimited documents storage (Zoho.com) and unlimited number of files transfer (mediafire.com), 1GB seems soooooo smalllllll.

Money!

It looks like to me that the site is not going to offer free stuff for very long. At some point I will end up paying to have all my documents. Or Thinkfree will use some sort of tatic to lure me into paying.

Security

All my documents are in one place, great, they are online! All the time… And there is a good chance that someone might see what I wrote. None of my docs are important but it feels pretty bad when someone read them.

How to Edit Grub’s Boot Menu – Adding an OS

I have been rewriting Grub’s boot menu many times. However, I would like to post it here for some of you guys and also for my future reference in case I forget how to do it. There is a lot of things and options in Grub so I will not be able to cover them all. I will only show you how to add an OS to your boot menu.

NOTE: Before trying this out, read my tutorial on how to recover grub just in case something goes wrong.

To edit Grub menu, we must use terminal.

Edit Grub Menu

  1. Open Terminal: Ctrl+Shift+T or Applications -> Accessories -> Terminal
  2. We need to see what OS is on which partition. Use the command below.

    df -h

      The output will be something like this.

  3. Take note which OS is on what partition. You can do that by looking at the size of the partition. For instance, one of my partitions (sda3) has 12G and mount on “/”, I know that is my Ubuntu partition. Likewise, sda1 has 47G and is my Windows partition. Remember these details, you are going to need them later (in step 9).
  4. Navigate to the grub folder

    cd /boot/grub

  5. Open the menu.lst file in Gedit so we can edit the file

    sudo gedit menu.lst

  6. Enter your password. Gedit will open the file with root authority.
  7. Scroll down to the part where it look somewhat like this

    title Ubuntu
    root (hd0,2)
    kernel /boot/vmlinuz-2.....
    initrd /boot/initrd.img.....
    quiet

  8. Now, to add an OS, follow the example below

    title XP
    root (hd0,0)
    makeactive
    chainloader +1

  9. Copy all the options above and paste it into your grub menu.lst, right below the existing options, you only need to modify the title and your root.
    In modifying your root, know that the hd0 means it’s your first hard drive, and the 0 after the comma tells the partition. My XP partition is in sda1, therefore, my root is (hd0,0). IF it was in sda2, my root would be (hd0,1). And so on, sda3 would result in (hd0,2). Adjust your option accordingly.
  10. After you are done modifying, save the file and close the application.

Now you have added a new OS into your booting.