Saturday, March 3, 2012

Some Command Line Differences

From LM12:
In the Gnome of LinuxMint 12 (LM) the default font for Gnome Terminal is set to the system fixed width font. This displays terminal windows that are too wide to fit my screen in quarters. If I change this setting to Monospace 10 I can see all the content of four terminals at once.

From OS12:
The default font for Konsole on Opensuse 12.1 (OS12) is Monospace 9; so I can see the contents of four without using the quarter screen snap feature. That quarter screen snap feature (for lack of knowing what it's really called) works nicely for Konsole windows.

I haven't found a way to have windows snap to quarter screen positions. Maximize, maximize left and right do snap into position.

mark@flounder:~$ cat $PATH
cat: /usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games: No such file or directory

Some of the commands I commonly use are in /sbin or /usr/sbin.

The only example of this I could think of on a Saturday is "ifconfig"

mark@flounder:~> ifconfig
Absolute path to 'ifconfig' is '/sbin/ifconfig', so running it may require superuser privileges (eg. root).
mark@flounder:~> /sbin/ifconfig
eth0 Link encap:Ethernet HWaddr 00:19:D1:4D:08:51
inet addr: Bcast: Mask:
RX packets:26888 errors:0 dropped:0 overruns:0 frame:0
TX packets:22931 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:29688290 (28.3 Mb) TX bytes:2727061 (2.6 Mb)

lo Link encap:Local Loopback
inet addr: Mask:
RX packets:216 errors:0 dropped:0 overruns:0 frame:0
TX packets:216 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:35010 (34.1 Kb) TX bytes:35010 (34.1 Kb)

mark@flounder:~> cat $PATH
cat: /home/mark/bin:/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/X11R6/bin:/usr/games:/usr/lib64/jvm/jre/bin:/usr/lib/mit/bin:.: No such file or directory

Having to type "/sbin" to run "ifconfig" (and some others) is a nuisance to me. Maybe it's just not what I'm used to. So I want to add /sbin to my $PATH on OS12.

mark@flounder:~$ ls -lh | grep D
drwxr-xr-x 2 mark mark 4.0K 2011-08-27 17:22 Desktop
drwxr-xr-x 3 mark mark 4.0K 2011-08-04 18:42 Documents
drwxr-xr-x 2 mark mark 4.0K 2012-02-26 09:08 Downloads

mark@flounder:~$ groups && cat /etc/
mark adm dialout cdrom audio video plugdev lpadmin admin sambashare vboxusers
Linux Mint 12 Lisa

The thing I want to point out here is file ownership; in particular group ownership. Notice the directories in my home that have the letter "D" are in the group "mark". Opensuse uses a different approach.

mark@flounder:~> ls -lh | grep D
drwxr-xr-x 2 mark users 4.0K Jan 29 12:24 Desktop
drwxr-xr-x 2 mark users 4.0K Feb 4 08:58 Documents
drwxr-xr-x 4 mark users 4.0K Feb 21 18:33 Downloads
mark@flounder:~> groups && cat /etc/
users video vboxusers
Welcome to openSUSE 12.1 "Asparagus" - Kernel %r (%t).

On OS12 all my files are in the group "users" and therefore visible by anyone else in the group users. I prefer to have a group named "mark" and have all my files in that group.

Tuesday, February 21, 2012

Font Sizes and Grub Stuff

And overall look are easy enough to change with different desktop themes.

In order to fix dual booting I had to add a stanza to OS12's /boot/grub/menu.lst. Below is a what the last two stanzas look like now.

###Don't change this comment - YaST2 identifier: Original name: linux###
title Desktop -- openSUSE 12.1 - 3.1.9-1.4
root (hd0,2)
kernel /boot/vmlinuz-3.1.9-1.4-desktop root=/dev/disk/by-id/ata-ST3500418AS_9VMRL8BM-part3 resume=/dev/disk/by-id/ata-ST3500418AS_9VMRL8BM-part7 splash=silent quiet showopts vga=0x31a
initrd /boot/initrd-3.1.9-1.4-desktop

###By me to dual boot to LinuxMint12
title LinuxMint12
root (hd0,0)
kernel /boot/vmlinuz-3.0.0-15-generic root=UUID=3f531261-e31c-4b42-bc95-933458c5d59c
initrd /boot/initrd.img-3.0.0-15-generic

Using the syntax that works for OS12 doesn't work for LinuxMint. Specifically the "/dev/disk/by-id/STRING-part1" part. Also using the LM symbolic links in / didn't work.

mark@flounder:/media/3f531261-e31c-4b42-bc95-933458c5d59c> ll vmlinuz
lrwxrwxrwx 1 root root 29 Feb 19 23:33 vmlinuz -> boot/vmlinuz-3.0.0-16-generic

mark@flounder:/media/3f531261-e31c-4b42-bc95-933458c5d59c> ll initrd.img
lrwxrwxrwx 1 root root 33 Feb 19 23:33 initrd.img -> /boot/initrd.img-3.0.0-16-generic

Do you see the subtle difference in the path in the symbolic links?

This means that I have to edit OS12's /boot/grub/menu.lst every time there is a new kernel for LM. I use Gvim to do that task.

The two sentences marked in red above are wrong! I think the first time I tried using the LM sym links I had the hd value for grub set incorrectly. I edited OS12's /boot/grub/menu.lst last night to read as follows: (Note I'm currently running LM booted from this change.)

###By me to dual boot to LinuxMint12
title LinuxMint12
root (hd0,0)
kernel /boot/vmlinuz-3.0.0-16-generic root=UUID=3f531261-e31c-4b42-bc95-933458c5d59c
initrd /boot/initrd.img-3.0.0-16-generic

### By me testing using the sym links in LM's /
title LinuxMint12T
root (hd0,0)
kernel /vmlinuz root=UUID=3f531261-e31c-4b42-bc95-933458c5d59c
initrd /initrd.img

I now have two entries for LinuxMint. Technically I could edit that file on the Opensuse partition and comment out the stanza I don't need but I think that might be risky.

Monday, February 20, 2012

Prolific Blogger

I truely am not a prolific blogger.

I started using blogger to see how it worked and to specifically write about Ubuntu. Well I stopped using Ubuntu with the first Unity release. I basically had to as I had freezes that I found impossible to diagnose or fix. So I switched to Xubuntu; quite nice but some things were awkward. I heard about this Linux Mint thing and that's what I'm using right now. It's Gnome something; at least that's how I think of it. (bad sentence there mark, ms. price would make you rewrite) I also wanted to give the latest KDE a try. So I installed Opensuse 12.1 KDE to dual boot with this LM install.

I'm wanting to give the latest Gnome and latest KDE a fair try. I've complicated matters by using a .deb based distro with a .rpm based distro in dual boot setup. I need to move along here...

OpenSuse still uses GRUB 1; I think that's why it didn't see my LM install at its install time. I couldn't boot to LM after installing OS12.1. So I managed to fix that by adding a stanza to OS12.1's menu.lst. (add exact path from os12(/boot/grub/menu.lst)) This is a crude hack because it specifies the exact kernel. So whenever LM updates its kernel I'll have to edit that file again.

After a month or so on OS12KDE I'm surprised at the difference in fonts sizes. That was the first thing I noticed. I'm taking a screen shot using the default app on LM.

Now I'm going to publish this post; close out stuff; reboot to OS12KDE; move some files around; add to this post.

Okay a few minutes later I'm back using OS12KDE. Now for a screen shot...

Ksnapshot is hard to find in the OS12KDE menu; I had to search using "screen shot" as my search parameter. Posting to see how they compare.

I've added all the links in the first paragraph from OS12.11KDE.