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:192.168.1.20 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
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:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
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/issue.net
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/issue.net
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.