Tuesday, April 12, 2005

Setting up Samba

1. Edit the /etc/smb script

[global]
workgroup = SIMPLE
encrypt passwords = true
[win_c]
comment = Windows XP volume
path = /mnt/win_c/
read only = no
guest ok = yes
[win_d]
comment = Data files volume
path = /mnt/win_d/
read only = no
guest ok = yes

[zxspectrum]
comment = Zx Spectrum games
path = /mnt/win_d/emulators/zxspectrum/gamedb
read only = no
guest ok = yes

[qemu]
comment = Temporary file space
path = /tmp
read only = no
public = yes

2. Make sure the drives you are sharing have permission to read/write by the user accessing the samab share. eg. I mount my /mnt/win_c as djohnson and I make sure my fstab file allows user to mount drives

# /etc/fstab: static file system information.
#
#
proc /proc proc defaults 0 0
/dev/hda1 / ext3 defaults,errors=remount-ro 0 1
/dev/hdc /media/cdrom0 udf,iso9660 ro,user,noauto 0 0
/dev/fd0 /media/floppy0 auto rw,user,noauto 0 0

/dev/hda2 /mnt/win_c vfat user,noauto 0 0
/dev/hda3 /mnt/win_d vfat user,noauto 0 0
/dev/hda6 /mnt/win_e vfat user,noauto 0 0


3. Add user to /etc/samba/smbpasswd file
sudo smbpasswd -a djohnson

Monday, April 11, 2005

Getting Linux NUT UPS software working with mecer UPS

1. First download NUT from here
2. Follow instructions here
3. In the file: /usr/local/ups/etc/ups.conf

Make sure you use the following driver

[myupsname]
driver = mustek
port = /dev/ttyS0
desc = "Workstation"

Sunday, April 03, 2005

Getting Ubuntu to automatically start user level programs when user logs in

If you want ubuntu to automatically login aparticular user and start user programs after login

From Gnome, Select Computer, System Configuration, Login Screen Setup.
Under Auomatic Login, Select check box: Login a user automatically on first bootup. Choose a user under: Automatic login username

To start programs automatically when user logs in edit the following script
~/.gnome2/session-manual

Here is my example:


[Default]
num_clients=3
0,RestartStyleHint=3
0,Priority=50
0,RestartCommand=x11vnc -shared -forever
1,RestartStyleHint=3
1,Priority=50
1,RestartCommand=mount /mnt/win_c
2,RestartStyleHint=3
2,Priority=50
2,RestartCommand=mount /mnt/win_d

Saturday, April 02, 2005

How to install LG -U56S USB modem in linux

Prerequisites

1. First download the driver from here(Make sure you Download the latest slmodem-x.x.x)
2. Make sure the the linux-headers package was installed
3. Change KERNEL_DIR:=/usr/src/linux-headers-2.6.8.1-3

Now run:
make

Change to root user, now run:
make install

recovering ubuntu grub after windows xp install

Recovering GRUB Manually

Before you can undertake the next step, it's important that you understand how GRUB identifies partitions.

To GRUB, numbers begin with 0, and letters are expressed numerically, also beginning with 0.

For example, /dev/hda1 is "hd0,0" to GRUB. Similarly, /dev/hdb3 is "hd1,2".

Note: The "root" line must point to the location of your /boot/ partition if you have one. If you do not have one, point it at your / partition.

/sbin/grub
grub> root (hd0,2)
grub> setup (hd0)
grub> quit