Author: Vince

Back Up PSX images in Linux

Credit goes to po0f for this. This is his script from the ubuntu forums, I’m just putting it in my blog so I can find it easily. Everything below was written by poOf.

This is a script I wrote to rip PSX images, it might work for others as well. You’ll need cdrdao installed for it to work. First, you need to do a little setup; namely, which CD drive to use (command you type is bolded, don’t really know why sudo access is needed):
Code:


$ sudo cdrdao scanbus
... snipping useless program output ...
ATA:1,0,0 TSSTcorp, CD/DVDW SH-S182M, SB02

We’re interested in the first field of the output, ATA:1,0,0. This is the way cdrdao names the devices. You might have more than one device in the output; just use the one that you will rip PSX CDs with.

Now, the script:
Code:


#!/bin/bash

if [[ -z "$1" ]]; then
echo -e "Usage: `basename $0` "
echo -e "Error: No filename specified."
exit 1
fi

cdrdao read-cd --device ATA:1,0,0 --driver generic-mmc-raw --read-raw --datafile $1.bin $1.toc

exit 0

Save this script as ‘mkpsximage’ in /usr/local/bin and give it execute permission. You’ll need sudo access to do this. (Change the bolded portion to whatever drive you want to use.) When you use the script, you will need to specify a base filename to use for the created BIN/TOC files. Say you were ripping Final Fantasy VII, disc one:

Code:


$ mkpsximage ff7-d1

When the script is finished, you should have two files in the current directory, ‘ff7-d1.bin’ and ‘ff7-d1.toc’.

Setting up Chromium in Ubuntu Linux

found a useful link on how to set up Chromium in Linux. Chromium is the open source browser that Google Chrome is based on. It might be because my thinkpad is a little older now, but Firefox is a little sluggish now, but Chromium is really, really fast. It’s still under development but it’s pretty usable now.

Updated for 9.10
credit goes to: http://a2b-net.com/software/chromium
Here is a quick install guide to install the Chromium Web Browser.

Open a Terminal window (Applications->Accessories->Terminal) and copy+paste following command:

sudo apt-key adv –recv-keys –keyserver keyserver.ubuntu.com 4E5E17B5

Then goto your Software Sources (System->Administration->Software Sources) and select the Other Software tab and click on the Add button. Now copy+paste the following line:

deb http://ppa.launchpad.net/chromium-daily/ppa/ubuntu karmic main

Now click on the Add Source button. And click the Reload button when asked.

In a Terminal window copy+paste the following command line:

sudo apt-get update && sudo apt-get install chromium-browser

Ubuntu 9.04
http://penguininside.blogspot.com/2009/08/how-to-setup-chromium-google-chrome.html

Here’s my summary. Add following line to your /etc/apt/sources.list:


deb http://ppa.launchpad.net/chromium-daily/ppa/ubuntu jaunty main #chromium-browser

Add the key so you won’t get an annoying message everytime you update apt:


sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0xfbef0d696de1c72ba5a835fe5a9bf3bb4e5e17b5

Install Chromium:


sudo apt-get update
sudo apt-get install chromium-browser

To use Extensions and Firefox Plugins launch chromium with these flags:


/usr/bin/chromium-browser --enable-plugins --enable-user-scripts --enable-extensions

The entry from the link above suggests making a desktop icon or creating an executable file to launch chromium with these abilities. I preferred the option to create /usr/local/bin/chrome-launcher:


#!/bin/bash
exec /usr/bin/chromium-browser --enable-plugins --enable-user-scripts --enable-extensions
exit 0

Enabling Thinkpad Trackpoint Scrolling in Ubuntu 8.04 LTS

This information was from thinkwiki.
Add the following to your /etc/X11/xorg.conf file

   Option          "EmulateWheel"          "on"
Option "EmulateWheelButton" "2"
Option "YAxisMapping" "4 5"
Option "XAxisMapping" "6 7"

Here is my xorg.conf


# xorg.conf (X.Org X Window System server configuration file)
#
# This file was generated by dexconf, the Debian X Configuration tool, using
# values from the debconf database.
#
# Edit this file with caution, and see the xorg.conf manual page.
# (Type "man xorg.conf" at the shell prompt.)
#
# This file is automatically updated on xserver-xorg package upgrades *only*
# if it has not been modified since the last upgrade of the xserver-xorg
# package.
#
# If you have edited this file but would like it to be automatically updated
# again, run the following command:
# sudo dpkg-reconfigure -phigh xserver-xorg

Section "InputDevice"
Identifier "Generic Keyboard"
Driver "kbd"
Option "XkbRules" "xorg"
Option "XkbModel" "pc105"
Option "XkbLayout" "us"
EndSection

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "EmulateWheel" "on"
Option "EmulateWheelButton" "2"
Option "YAxisMapping" "4 5"
Option "XAxisMapping" "6 7"
EndSection

Section "InputDevice"
Identifier "Synaptics Touchpad"
Driver "synaptics"
Option "SendCoreEvents" "true"
Option "Device" "/dev/psaux"
Option "Protocol" "auto-dev"
Option "HorizEdgeScroll" "1"
EndSection

Section "Device"
Identifier "Configured Video Device"
Driver "fglrx"
EndSection

Section "Monitor"
Identifier "Configured Monitor"
EndSection

Section "Screen"
Identifier "Default Screen"
Monitor "Configured Monitor"
Device "Configured Video Device"
Defaultdepth 24
EndSection

Section "ServerLayout"
Identifier "Default Layout"
screen "Default Screen"
Inputdevice "Synaptics Touchpad"
EndSection
Section "Module"
Load "glx"
EndSection

Add new user on Ubuntu server

sudo useradd -d /home/testuser -m testuser admin
sudo passwd testuser

the admin at the end makes testuser part of hte admin group. you do not need to add it to the end. you can also just edit the /etc/group file and manually add testuser to the admin group.

info from here: http://www.howtogeek.com/howto/ubuntu/add-a-user-on-ubuntu-server/
http://ubuntuforums.org/showthread.php?t=201468
http://linuxservertutorials.blogspot.com/2008/11/ubuntu-create-group.html

Installing a new hard drive in linux

I installed the new hard drive and powered on the system.

1. I used fdisk /dev/sda, then I used the print command p to make sure which /dev I was going to format. I wish I knew a better way of finding where the hard drive was, but I’ll have to look it up another time.

2. In fdisk use n to create a new partition.

3. Choose to create an extended or primary partition. I will create a primary partition so I will choose p. If you decided to create an extended partition you will need to create a logical partition inside of it after this set.

4. For partition number I will choose 1, as this will be the first partition.

5. For the first cylinder I will just leave it blank and let it fall to the default value of 1.

6. For the alst cylinder leave it the default value if you wish to use the entire drive. If you want to create multiple partitions then specify the last cylinder or size of your desired partition here.

7. Enter p to print the partition table. Verify everything is correct.

8. Enter w to write your changes to the partition and exit fdisk.

9. Now to format the drive and create the file system. use the following command:
mkfs -t ext3 /dev/sda1
where ext3 is the filesystem type you want to use and sda1 is the partition I just created.

10. Now mount your new drive.
note that on ubuntu systems the filesystem will be automactically checked every 23 mounts or 180 days, whichever comes first. You can use tune2fs -c or -i to override.

There’s a better tutorial over here:
http://www.yolinux.com/TUTORIALS/LinuxTutorialAdditionalHardDrive.html