Contents
- How I got suspend to disk working
- Enable mounted CDs to be ejected when eject button is pushed
- Install and set up Nvidia binary driver
- Disable second sound card so that flash will work
- Get Samsung SCX-4100 printer and scanner working
- Get Samsung SCX-4521F printer and scanner working
- Get Minolta Magicolor 2300 DL printer working
Hardware Tips for Ubuntu and Kubuntu
How I got suspend to disk working
I tried for a long time to get suspend to ram working, but I couldn't get my PC to wake up properly.
Here's how I got suspend to disk working (adapted from Experimental Dapper and suspend2 packages):
Note: I don't use the nvidia driver anymore. Instead I use the open source "nv" one because suspending to disk didn't work right for me with the binary Nvidia driver. So if you have a nvidia card make sure you are using the open source "nv" driver.
Add this line to your /etc/apt/sources.list:
deb http://dagobah.ucc.asn.au/ubuntu-suspend2 dapper/
Run:
sudo apt-get update
Run:
sudo apt-get install suspend2
Find the name of your swap partition:
grep swap /etc/fstab
Should output something like this:
/dev/sda5 none swap sw 0 0
That would mean that /dev/sda5 is the name of your swap partition, remember this
Open /boot/grub/menu.lst and find a line like this:
# kopt=root=/dev/sda3 ro
Add something like " resume2=swap:/dev/sda5" to the end of it so it looks something like this (replace /dev/sda5 with the name of your swap partition):
# kopt=root=/dev/sda3 ro resume2=swap:/dev/sda5
Run:
sudo update-grub
- Reboot your PC into the new kernel
To suspend to disk run:
sudo hibernate
- Then next time you turn on your PC, everything you had open should be restored on boot up.
Enable mounted CDs to be ejected when eject button is pushed
NOTE: I DON'T DO THIS ANYMORE AND I DO NOT RECOMMEND YOU DO IT! It makes tons of errors be spewed into /var/log/messsages
-
Open /etc/sysctl.conf and add the following line:
dev.cdrom.lock=0
- Reboot your computer.
Install and set up Nvidia binary driver
Follow the BinaryDriverHowto/Nvidia page in the Ubuntu wiki.
Note: I don't use the nvidia driver anymore. Instead I use the open source "nv" one because suspending to disk didn't work right for me with the binary Nvidia driver.
Disable second sound card so that flash will work
Add a line like the following to /etc/modprobe.d/blacklist
blacklist snd_ens1371
Get Samsung SCX-4100 printer and scanner working
Last updated: March 1, 2008, I can't seem to get my scanner working on Gutsy :/
-
First, you need to install some required libs and programs:
sudo apt-get install libstdc++2.10-glibc2.2 libsane-dev sane sane-utils
- Download the Linux driver from the SCX-4100 Downloads page
-
Open a terminal and change to the directory where you downloaded the driver (example: /home/install/samsung-scx-4100-printer):
cd /home/install/samsung-scx-4100-printer
-
Extract the driver (the driver could be named something different if it has been updated):
tar -xzf 20070725084555687_UnifiedLinuxDriver.tar.gz
-
Start the driver installation script:
sudo ./cdroot/Linux/install.sh
- Press "4" because you want to install the "[4] SCX 4100 Series" driver
- Press "1" since you want to "[1] Install driver package".
-
You should already have CUPS installed so Press "2":
[2] I am sure I have necessary software installed. Continue installation
- You'll get a whole spew of stuff printed on the screen along with some errors that you can probably just ignore.
-
Open /etc/cups/printers.conf Under "DefaultPrinter scx4100" change the "DeviceURI" so it looks like this:
DeviceURI file:/dev/usblp0
-
Restart cups:
sudo /etc/init.d/cupsys restart
- If printer gets stuck in a stopped state do the following (on KDE, I assume Gnome has something similar)
- Click on "K Menu -> System Settings"
- Click on "Printers"
- The "scx4100" printer should already be selected, if not click on it.
- Click on the "Printer" button near the top.
- From the drop-down click on "Start/Stop Printer -> Start Printer"
- Printing should now work.
Add the following 2 lines near end of /etc/udev/rules.d/45-libsane.rules (use sudo with your favourite text editor)
# Samsung|SCX-4100
SYSFS{idVendor}=="04e8", SYSFS{idProduct}=="3413", MODE="664", GROUP="scanner"Be sure to put it before LABEL="libsane_rules_end"
All this does is make sure that the permissions for the device file is correct and setting its group to scanner. The device is identified by the vendor id and product id. So all users in group scanner will now have access to the scanning functions.
-
Add the following 2 lines to the end of /etc/udev/rules.d/60-symlinks.rules (use sudo with your favourite text editor)
# Create symlink for usb printer to /dev/usb/lp*
BUS=="usb", KERNEL=="lp[0-9]*", SYMLINK+="usb/%k"A usb printer is assigned the device file /dev/usblp0 (or whichever number at the end). See /etc/udev/rules.d/20-names.rules which is where it is assigned. These lines make sure that the devices are also symlinked to /dev/usb/lp0.
These rules will be read and executed on startup so no other startup scripts are necessary.
You don't have to restart just execute:
sudo /etc/init.d/udev restart
This will restart udev.
- Scanning using OpenOffice.org (Insert -> Picture -> Scan -> Request), and the GIMP (File -> Aquire -> xscanimage -> Device dialog...) should now work.
Get Samsung SCX-4521F printer and scanner working
The Samsung SCX-4521F is a Laser Multifunction Printer, Copier, Fax, and Color Scanner. On the Samgung SCX-4521F Specifications page it says that is is compatible with the "Linux OS (via USB interface only) including Red Hat 8.0-9.0; Fedora Core 1 to 3, Mandrake 9.0 to 10.2, and SuSE8.2 to 9.2". I have successfully gotten the SCX-4521F working with Kubuntu Linux Dapper Drake. This how to has been reported to work in Mepis 6 beta 5. This how to has also been reported to work with the SCX-4100.
I found the tips on Samsung SCX-4100 Linux Installation page useful when trying to get the SCX-4521 working. To get the SCX-4521 printer and scanner working in Kubuntu (or Ubuntu) Linux:
-
First, you need to install some required libs and programs:
sudo apt-get install libstdc++2.10-glibc2.2
sudo apt-get install libsane-dev sane sane-utils - Download the updated driver from the SCX-4521F Linux driver download page.
-
Open a terminal and change to the directory where you downloaded the driver (example: /home/install/samsung_printer):
cd /home/install/samsung_printer
-
Extract the driver (the driver could be named something different if it has been updated):
tar -xzf 20051130084513156_DriversPack-1.0.165.tar.gz
-
Start the driver installation script:
sudo ./cdroot/Linux/install.sh
- Press "6" because you want to install the "[6] SCX 4x21 Series" driver
- Press "1" since you want to "[1] Install driver package".
-
You should already have CUPS installed so Press "2":
[2] I am sure I have necessary software installed. Continue installation
- You'll get a whole spew of stuff printed on the screen along with some errors that you can probably just ignore.
-
Open /etc/cups/printers.conf Under "DefaultPrinter scx4x21" change the "DeviceURI" so it looks like this:
DeviceURI file:/dev/usblp0
-
Restart cups:
sudo /etc/init.d/cupsys restart
- Printing should now work.
-
Add 2 lines like this to the end of /etc/udev/rules.d/45-libsane.rules before the LABEL="libsane_rules_end" line (based on output of sane-find-scanner) so that people in the "scanner" group and not only root can use the scanner. (You'll have to reboot after doing this.):
{literal}# Samsung|SCX-4521F
SYSFS{idVendor}=="04e8", SYSFS{idProduct}=="3419", MODE="664", GROUP="scanner" -
Restart udev:
sudo /etc/init.d/udev restart
-
Create a symlink that is required to for Xsane to be able to see the scanner:
sudo mkdir /dev/usb
sudo ln -sfn /dev/usblp0 /dev/usb/lp0 - Now to keep from having to type the above commands after every reboot, do the following (thanks to Olivier Vogel for this info!):
- Create the file /etc/init.d/samsung.sh with the content:
#!/bin/bash
mkdir -p /dev/usb
ln -sfn /dev/usblp0 /dev/usb/lp0 - Make it executable with the command:
sudo chmod 775 /etc/init.d/samsung.sh
- Make it be run on every boot:
sudo update-rc.d samsung.sh defaults
- Create the file /etc/init.d/samsung.sh with the content:
- Scanning using "xsane", OpenOffice.org (Insert -> Picture -> Scan -> Request), and the GIMP (File -> Aquire -> xscanimage -> Device dialog...) should now work.
Fix xsane crashing on Kubuntu
By default Kubuntu makes GTK applications use KDE styles. This sometimes causes problems, and in this case it causes xsane to crash.
Here's how to make the Ubuntu Human style be used for GTK programs:- First install the "'ubuntulooks' theme for GTK+ 2.x ":
sudo apt-get install gtk2-engines-ubuntulooks
- Open: K Menu -> System Settings"
- Click on "Appearance" in the top left corner.
- Click on "GTK styles and fonts"
- Under "GTK Styles" select "Use another style:" and choose "Human" from the drop-down list.
- Click the "Apply" button.
- There, you should no longer get a "Segmentation fault" when you start xsane. (Side note: I think if you log out and back in the colors used in GTK programs will no longer be orange, but will use your Kubuntu blue.)
Get Minolta Magicolor 2300 DL printer working
To get the Minolta Magicolor 2300 DL printer working you just need to follow the instructions on the foo2zjs driver page. You need to install the "build-essential" package to use the "make" command to build the driver. Install it by running this command:
sudo apt-get install build-essential