Advanced Topics
From PCLinuxOS Wiki
| Video DVD | Custom Software install via LiveCD | Configure Iptables |
|---|---|---|
| . | . | . |
| . | . | . |
|
Installing PCLinuxOS Manually
You can install the LiveCD by booting the LiveCD and starting the LiveCD installer, which should install PCLinuxOS for you nice and easy. If you have problem with the livecd-installer, here are the steps that you can take:
Login as root Open a konsole type draklive-install
If all this fails and you still have problems, try the method that Knoppix calls the poor man install: installing a new PCLinuxOS without burning the ISO, directly from the hard drive. As a matter of fact, I would recommend this method to everybody who has any Linux already installed.
The way to achieve that is to copy the content of the livecd into this partition. Then you can boot the livecd with livecd bootfrom=/dev/hdXx where hdXx is the partition you copied the /isolinux directory and the livecd.sqfs file. If you add the changes=/dev/hdXx parameter on the boot, then it will even save all the modifications you made in your "non installed" iso.
Supposing you downloaded the iso into the /tmp/pclinuxosp92.iso from your current install. You can copy the necessary files with the following commands:
mkdir /mnt/loop mount –o loop /tmp/pclinuxosp92.iso /mnt/loop cp –av --preserve /mnt/loop/* /
or for people who prefer GUI, there is a handy KDE utility Kiso, available for this in synaptics.
Best of all you can even create a "boot" floppy to boot this setup not from a cd, but from the boot floppy. That basically can be done with lilo (where you create the lilo on floppy).
In the following example my PCLinuxOS install is on the /dev/hdb12, the partition where I copied the livecd’s contents.
My /etc/lilo.floppy which is demonstrating this is here:
default="PCLinuxOS.91" boot=/dev/fd0 map=/mnt/floppy/map prompt nowarn timeout=100 image=/boot/vmlinuz label="PCLinuxOS.91" root=/dev/hdb12 initrd=/boot/initrd.img append="noapic nolapic nomce devfs=nomount acpi=ht splash=verbose" vga=791 read-only other=/dev/hda2 label="WindowsXP" table=/dev/hda image=/mnt/removable1/isolinux/vmlinuz label="liveusb" root=/dev/sda1 initrd=/mnt/removable1/isolinux/initrd.gz append="noapic nolapic nomce devfs=nomount acpi=ht splash=silent debug bootfrom=/dev/sda1" vga=788 read-only image=/isolinux/vmlinuz label="livehd" root=/dev/hdb12 initrd=/isolinux/initrd.gz append="noapic nolapic nomce devfs=nomount acpi=ht splash=silent debug bootfrom=/dev/hdb12 changes=/dev/hdb12" vga=788 read-only
and the commands to install it on the floppy are:
fdformat /dev/fd0 mke2fs /dev/fd0 mount /mnt/floopy lilo -C /etc/lilo.floppy -b /dev/fd0 -i /mnt/floppy/boot.b –c
Configuring system services
Managing Services
Services, sometimes known as daemons, run on your PC waiting for connections from "clients". A client may be another process, the local user, or a remote user.
For example, consider cups. If you have the cups service running, you can go to http://127.0.0.1:631 in any browser and see the management page and watch as the cups daemon accepts connections from your web browser and printer.
Services can be called daemons (usually reserved for *nix) and processes (Windows).
Finding Superfluous Services
Since unknown and superfluous services create perfomance slowdowns and are possible security vulernabilities, the below steps should be taken to manage them appropriately:
1) See what services you have running at boot. This can be done via the control center, or by issuing the command "chkconfig --list" as root. 2) Look at what services you have running, and at what "run-level". Do not worry about the run-level part yet. 3) Of the services you have running at boot, are there any that shouldn't be? You could email the entire list to the PCLinux mailing list if you aren't sure. Ones to watch out for are httpd (web server), sendmail (mail server), ssh (remote access), vnc (remote access), cups (printing). 4) Disable the services you don't need. If you aren't sure consult google or the mailing list. You can shut down services by using the command "chkconfig --levels 2345 <service name> off". 5) Reboot your system. 6) Immediately login and open a terminal. As root, issue the command netsta -l and look for listening services making connections. 7) Repeat as necessary.
In many cases you will want a service to run at boot, or by issuing the command service <daemon name> start. To start a service at boot, "chkconfig --levels 2345 <daemon name> on" will make the connection start at boot.
Using Partimage on SystemRescueCD
If you're like me, after you get your great PCLinuxOS installed and all the programs downloaded with Synaptic and your Desktop configured you want to explore and tinker with the monitor or nVidia or other things. But, before you start to hack your system, you might consider backing up that partition.
This is for users who have one hard disk with two partitions, one for the OS and the other for /home/joe_user. These partitions are usually labeled hda1 and hda2 by the OS. In order to back up hda1, i.e., root and all your programs and settings, you need to download SystemRescueCD and burn it to a CD. This will allow you to use one of its programs, Partimage to backup your hda1 partition to the second partition, hda2 so that later you can save it somewhere else or just leave it there, ready to be used in case you bork up the system.
After you have SystemRescueCD, place the cd in the drive and reboot. Answer the basic questions about your keyboard, etc. and then when the program does no more, we can create the directory on hda2 where Partimage will create the backup. We will use backup as our directory. Type this:
mkdir /mnt/backup
Then mount this directory so it can be accessed or used by Partimage. Type:
mount /dev/hda2 /mnt/backup
We don't do anything with the first partition, hda1, since it cannot be mounted and be copied by PartitionImage at the same time.
Now Run/Launch Partimage by typing:
partimage
Now, using the Partimage program, select your first partition: hda1. In the space or line for "Image file to create...", type:
/mnt/backup/PCLinux_backup_new_install
Continue through the rest of the windows until you come to one which has Automatic Split. Make sure this is checked, continue on and finally Partimage will begin to copy your first partition to your second one.
When the program finishes we need to unmount that partition. Type:
umount /mnt/backup
The above is not unmount, but umount. When that finishes, type:
sync
Exit Partimage and when you get the black window, type:
reboot
and remove your cd from the drive.
Congratulations! You now have a backup of your root partition!
Many thanks to the guys at www.sysresccd.org/forums, especially skywalkin1138 for his great post.
Custom software installation using livecd
When you install from the live CD , you got the option to open Synaptic and " unmark " all the aps that you "' do not want "" installed. Put LiveCd in tray. Boot up When asked if " root " or " guest "...choose root. Before clicking the " install " icon , go to the task bar and click Package Manager icon. Now , do NOT reload. Just uninstall what you don't want. Close Synaptic.
Then click " install " and proceed as usual. thx xena for this tip
Advanced_Topics > Using Kpilot
At this point this is specifically for a Palm Tungesten E and Kpilot, but you might try some of the ideas with your PDF...
See... http://www.faqs.org/docs/Linux-mini/Handspring-Visor.html for more information.
In your Menu make sure you have Kpilot. Menu, Applications, Office, Communications, Kpilot.
Then, in Synaptic, make sure you also have the following installed:
kdepim
kdepim-kpilot
libpisock9
libpisync0
Do not install pilot-link from Synaptic. Kpilot has it built in and when you
install pilot-link as well the connection does not work.
Click on Kpilot to run it.
Go to Settings->Configure Kpilot->Device
Where is says /dev/pilot change it to /dev/ttyUSB1
Now, connect your device and click the Sync button.
Then to test, run the following commands as root in a Terminal:
/sbin/modprobe usb-uhci /sbin/modprobe usb-ohci /sbin/modprobe visor
Then, if the icon appears on your Desktop, you can click on it and it will run Kpilot and begin to sync.
If not, disconnect your Palm. Wait a minute or so. Quit Kpilot. Connect your Palm again, turn it on and hit the Sync button.
Wait another minute or so.
If nothing appears on the Desktop, go ahead and run Kpilot. It should begin syncing.
If the above works, then you can have the visor module autoload on boot by adding it to the file
/etc/modprobe.preload
as root by typing "visor" on the last line of the file without the quotation marks.
If, when you sync, your Palm produces some error messages, for example when trying to sync the ToDo component, or one of the others, see KythingFlutes' post for help>
http://www.pclinuxos.com/index.php?option=com_smf&Itemid=26&topic=30975.msg238178#msg238178
All thanks to the brave souls in this post>
http://www.pclinuxos.com/index.php?option=com_smf&Itemid=26&topic=26136.0
as well as this one>
http://www.pclinuxos.com/index.php?option=com_smf&Itemid=26&topic=26136.0
Have a great day! :)
--Frazelle09 01:38, 28 October 2007 (EDT)
Simple File Encryption with GPG
The simplest way to encrypt a file is to use symmetric encryption.
- On the KDE desktop, right click on any file, highlight "actions", then "encrypt file".
- From the command line, "gpg -c <filename>" will encrypt the file.
In both cases, a new file is created. The new file requires a passphrase to open, specified when encrypting.
File Encryption with keepass
Keepass is a utility designed for storing large numbers of website passwords securely, although it also accepts attachments. It is cross platform, and can be used to securely store almost any type of data.
Keepass has an active forum for new and advanced users.
Sending Encrypted Mail with Thunderbird
Back to Advanced Topics
To send encrypted mail with Thunderbird, you need the Firefox extension Enigmail, and you should probably install the kdeutils package also.
The enigmail plugin will allow you to do four things:
- Digitally sign email, so the recipient knows that it came from you.
- Check other people's digital signatures to verify the email came from them.
- Encrypt an email using someone else's public key so only someone with the recipient's private key can open the mail.
- Decrypt mail that is encrypted with your public key.
Overview
GPG is a free replacement for PGP. There are two types of encryption GPG supports - asymmetric and symmetric. Asymmetric encryption allows you to send an email that is encrypted in a way that no one (not even the sender) but the recepient can read it. Symmetric encryption will let anyone decrypt the file, but requires that a single passphrase, known to the person encrypting and the person decrypting be used.
Email encryption with enigmail uses asymmetric encryption because:
- It allows the sender to encrypt mail without knowing the receipient's passphrase.
- The encryption and decryption process does not require a key distribution center, or any other centralized servers.
Starting to use Enigmail
Read the instructions here. Make sure to put /usr/bin/gpg under enigmail -> preferences -> GnuGPG Executable path.
In general, the process for sending encrypted mail is:
- Get the recipient's public key.
- Sign your message with your key.
- Encrypt the email with the recpient's public key.
Other GPG-enabled Mail Clients
PCLinuxOS can use the below email clients, all of which have built in PGP-compliant support.
- Evolution (excellent UI)
- Kmail
- Sylpheed-Claws
Symmetric Command-Line Encryption
To encrypt a single file with a passphrase, open a command prompt and enter gpg -c <filename> and follow the instructions. To decrypt this file, enter the command gpg <filename.gpg> and provide the passphrase you made when you encrypted the file.
kgpg well integrated with the KDE desktop, and can be used to encrypt files without using the command line. Right click on a file, choose "actions" then "encrypt file". There is a checkbox for specifying the use of symetric encryption.