https://wiki.archlinux.org/api.php?action=feedcontributions&user=Tkjacobsen&feedformat=atomArchWiki - User contributions [en]2024-03-29T12:29:42ZUser contributionsMediaWiki 1.41.0https://wiki.archlinux.org/index.php?title=SSH_keys&diff=52847SSH keys2008-11-07T12:53:05Z<p>Tkjacobsen: /* Step 2+3 - The easy way */</p>
<hr />
<div>[[Category:Networking (English)]]<br />
[[Category:Security (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Using_SSH_Keys}}<br />
{{i18n_entry|Русский|Использование_SSH_ключей}}<br />
{{i18n_links_end}}<br />
<br />
===Using SSH-keys to connect to a server===<br />
====Why use those keys?====<br />
Using ssh-keys, a public and a private key to be precise, is an easy way to connect to a server/a whole bunch of servers, using the same password ''OR'' using no password at all. You should prefer the password/ssh-agent combination!<br><br />
<br />
====Step 1: generate the keys====<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-keygen -b 1024 -t dsa<br />
Generating public/private dsa key pair.<br />
Enter file in which to save the key (/home/mith/.ssh/id_dsa):<br />
Enter passphrase (empty for no passphrase):<br />
Enter same passphrase again:<br />
Your identification has been saved in /home/mith/.ssh/id_dsa.<br />
Your public key has been saved in /home/mith/.ssh/id_dsa.pub.<br />
The key fingerprint is:<br />
x6:68:xx:93:98:8x:87:95:7x:2x:4x:x9:81:xx:56:94 mith@middleearth<br />
mith@middleearth||[[~]]:~ ><br />
</pre><br />
<br><br />
What did we do? We generated a 1024 bit long (<code>-b 1024</code>) public/private dsa (<code>-t dsa</code>) key pair with the <code>ssh-keygen</code> command. You can also create a rsa key (<code>-t rsa</code>). You can leave out the bit length parameter (default bit length is 1024).<br><br />
In case you don't like the standard key name you can specify a name using the <code>-f name</code> parameter.<br><br />
In the process you are asked for a place to save your keys. I kept the standard path. Then you are asked for a passphrase. <br><br />
Now there are two paths which you can follow or ''"Choose your destiny"'' (as the guy from Mortal Kombat would say):<br><br />
'''a)''' ''the short, easy but insecure way'': use no passphrase, have easy access to your remote-server, feel paranoid about someone stealing your private key<br><br />
'''b)''' ''the a bit longer, slightly less comfortable but secure way'': use a passphrase, use ssh-agent and feel safe<br />
<br />
====Step 2: copy your public key to the remote server {SAME for path A and B}====<br />
<pre><br />
mith@middleearth||[[~]]:~ > scp .ssh/id_dsa.pub mith@metawire.org:<br />
</pre><br />
<br><br />
Copy the public key (<code>id_dsa.pub</code>) to your remote server via scp (note the '''<code>:</code>''' at the end of the server address. That way the file actually ends up in our server home directory but you can specify another path if you like.<br><br />
<br />
====Step 2+3 - The easy way====<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-copy-id -i .ssh/id_dsa.pub mith@metawire.org<br />
</pre><br />
DONE!<br />
<br />
NOTE: that as the username on both machines is the same you can omit it in the command (i.e. metawire.org instead of mith@metawire.org).<br />
<br />
====Step 3: login to the remote computer and put your key into the right place {SAME for path A and B}====<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh metawire.org<br />
mith@metawire.org's password:<br />
-bash-2.05b$ mkdir .ssh/<br />
-bash-2.05b$ cat id_dsa.pub >> .ssh/authorized_keys<br />
-bash-2.05b$ rm id_dsa.pub<br />
-bash-2.05b$ chmod 700 .ssh<br />
-bash-2.05b$ chmod 600 .ssh/authorized_keys<br />
</pre><br />
<br><br />
We connect to our remote server and use cat to add the content of <code>id_dsa.pub</code> to <code>authorized_keys</code> which is in the hidden directory <code>.ssh</code>. ''NOTE:'' In case you get an error because the <code>.ssh</code> directory doesn't exist you should simply create it (<code>mkdir .ssh</code>).<br><br />
Now we remove the public key (<code>rm id_dsa.pub</code>) and set the correct permissions for <code>.ssh</code> and <code>authorized_keys</code>.<br><br />
Log out and re-login. Depending on the path you chose, you will/won't be asked for a passphrase. '''Path a ends here...'''<br />
<br><br />
<br />
====...path b continues...====<br />
Now what makes this path almost as easy as a no-passphrase key? The magic word is ssh-agent.. What it does is basically asking you once every session for the passphrase of your private key and every time you would have to type it in, <code>ssh-agent</code> does it for you. <code>ssh-agent</code> is included in the <code>openssh</code> package so no trouble there...<br><br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-agent<br />
SSH_AUTH_SOCK=/tmp/ssh-vEGjCM2147/agent.2147; export SSH_AUTH_SOCK;<br />
SSH_AGENT_PID=2148; export SSH_AGENT_PID;<br />
echo Agent pid 2148;<br />
</pre><br />
<br><br />
When you run <code>ssh-agent</code> it will print out what environment variables it would use... Well to make <code>ssh-agent</code> use these variables run<br />
<pre><br />
mith@middleearth||[[~]]:~ > eval `ssh-agent`<br />
Agent pid 2157<br />
</pre><br />
The process id will vary for you of course. Adding <code>eval `ssh-agent`</code> to your <code>.bashrc</code> is an option so it's started every time you create a new shell.<br><br />
Now that the <code>ssh-agent</code> is running, we need to tell it that we have a private key and where that is.<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-add .ssh/id_dsa<br />
Enter passphrase for .ssh/id_dsa:<br />
Identity added: .ssh/id_dsa (.ssh/id_dsa)<br />
</pre><br />
<br><br />
We were asked for our passphrase, entered it, that's all. Now you can login to your remote server without having to enter your password while your private key is password-protected. Sweet isn't it? The only downside is that a new instance of <code>ssh-agent</code> needs to be created for every new console (shell) you open, that means you have to run <code>ssh-add</code> every time again on each console. There is a workaround to that with a program or rather a script called [http://www.gentoo.org/proj/en/keychain/index.xml keychain] which is covered in the next section.<br />
<br />
====Using keychain====<br />
[http://www.gentoo.org/proj/en/keychain/index.xml Keychain] manages one or more specified private keys. When initialized it will ask for the passphrase for the private key(s) and store it. That way your private key is password protected but you won't have to enter your password over and over again.<br />
<br />
Install keychain from the extra repo:<br />
# pacman -S keychain<br />
Edit your <code>~/.bashrc</code> and add the following lines:<br />
<pre><br />
/usr/bin/keychain -Q -q ~/.ssh/id_dsa<br />
[[ -f $HOME/.keychain/$HOSTNAME-sh ]] && source $HOME/.keychain/$HOSTNAME-sh<br />
</pre><br />
If necessary, replace <code>~/.ssh/id_dsa</code> with <code>~/.ssh/id_rsa</code>. For those using a non-Bash shell, see <code>keychain --help</code> or <code>man keychain</code> for details on other shells.<br />
<br />
Close your shell and open it again. Keychain should come up and if it's your first run it will ask your for the passphrase of the specified private key.<br />
<br />
====Using ssh-agent and x11-ssh-askpass====<br />
You need to start the ssh-agent everytime you start a new Xsession. The ssh-agent will be closed when the X session ends.<br><br />
Install x11-ssh-askpass which will ask your passphrase everytime you open a new Xsession:<br><br />
<code>sudo pacman -S x11-ssh-askpass</code><br />
<br />
Prepend this into your <code>~/.xsession</code> :<br />
<pre><br />
eval `/usr/bin/ssh-agent`<br />
SSH_ASKPASS=/usr/lib/openssh/x11-ssh-askpass ssh-add < /dev/null<br />
# then the end of the file with for example "exec dwm"<br />
</pre><br />
<br />
====SSH connection control====<br />
In ~/.ssh/config, add the following lines: <br />
host *<br />
controlmaster auto<br />
controlpath /tmp/ssh-%r@%h:%p<br />
What this does is set a "master control" socket when you make an SSH connection. The socket is named based on the <code>controlpath</code> setting (<code>%r</code> = username, <code>%h</code> = hostname, <code>%p</code> = port). <br />
<br />
This master socket is used for each successive connection after the first, as long as one connection still exists. That is, if you connect via <code>ssh myuser@myhost.com</code>, a socket named <code>/tmp/ssh-myuser@myhost.com:22</code> is created. If you then ssh again to the same host, the socket is found and the remote ssh session is told to spawn a new shell. This shell does not require a login, and spawns immediately, as you're already logged in.<br />
<br />
<br />
===PuTTY===<br />
The above procedure is a bit complicated when using PuTTY on Windows since PuTTY can't directly use keys generated by ssh-keygen. The private key needs to be converted using PuTTYgen which you can find [http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html here]. The procedure is then as follows:<br />
#Generate the key pair with ssh-keygen on you Linux computer (you can log in with your usual username/password using PuTTY)<br />
#Add the public key to the ''~/.ssh/authorized_keys'' file<br />
#Move the private key to the Windows machine<br />
#Load the private key with PuTTYgen and click ''Save private key''. This will convert the key so that PuTTY can use it.<br />
#Start PuTTY, go to ''SSH''->''Auth'' and find the private key. Then simply connect to your Linux machine. You will be prompted for your username and passphrase (if you chose to enter one when you generated the keys).<br />
Note that reversing the procedure, that is, generating the key pair with PuTTYgen and converting the public key with ssh-keygen, will NOT work.<br />
<br />
<br />
===Useful links / information===<br />
* [http://www.puddingonline.com/~dave/publications/SSH-with-Keys-HOWTO/document/html-one-page/SSH-with-Keys-HOWTO.html SSH with Keys HOWTO]<br />
* [http://www.arches.uga.edu/~pkeck/ssh/ HOWTO: set up ssh keys]<br />
<!-- Not Found + [http://particle.phys.uvic.ca/doc_sshkey.html ] --><br />
* [http://www-106.ibm.com/developerworks/linux/library/l-keyc.html OpenSSH key management, Part 1]<br />
* [http://www-106.ibm.com/developerworks/linux/library/l-keyc2/ OpenSSH key management, Part 2]<br />
* [http://www-106.ibm.com/developerworks/library/l-keyc3/ OpenSSH key management, Part 3]<br />
* [http://kimmo.suominen.com/docs/ssh/ Getting started with SSH]<br />
* Manual Pages: [http://www.openbsd.org/cgi-bin/man.cgi?query=ssh-keygen&apropos=0&sektion=0&manpath=OpenBSD+Current&arch=i386&format=html ssh-keygen(1)]<br />
* [http://blog.eukhost.com/2006/11/24/sharing-ssh-keys-on-2-linux-servers-to-login-without-authentication/ Sharing SSH keys on 2 linux servers]<br />
* [http://www.andremolnar.com/how_to_set_up_ssh_keys_with_putty_and_not_get_server_refused_our_key How to set up SSH keys: Frustration with "Server refused our key" [PuTTY]]<br />
* [http://blog.webhosting.uk.com/2007/04/01/securing-your-secure-shell-ssh-service/ Securing your secure shell (SSH) service]</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=SSH_keys&diff=52846SSH keys2008-11-07T12:51:09Z<p>Tkjacobsen: /* Step 2+3 - The easy way */</p>
<hr />
<div>[[Category:Networking (English)]]<br />
[[Category:Security (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Using_SSH_Keys}}<br />
{{i18n_entry|Русский|Использование_SSH_ключей}}<br />
{{i18n_links_end}}<br />
<br />
===Using SSH-keys to connect to a server===<br />
====Why use those keys?====<br />
Using ssh-keys, a public and a private key to be precise, is an easy way to connect to a server/a whole bunch of servers, using the same password ''OR'' using no password at all. You should prefer the password/ssh-agent combination!<br><br />
<br />
====Step 1: generate the keys====<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-keygen -b 1024 -t dsa<br />
Generating public/private dsa key pair.<br />
Enter file in which to save the key (/home/mith/.ssh/id_dsa):<br />
Enter passphrase (empty for no passphrase):<br />
Enter same passphrase again:<br />
Your identification has been saved in /home/mith/.ssh/id_dsa.<br />
Your public key has been saved in /home/mith/.ssh/id_dsa.pub.<br />
The key fingerprint is:<br />
x6:68:xx:93:98:8x:87:95:7x:2x:4x:x9:81:xx:56:94 mith@middleearth<br />
mith@middleearth||[[~]]:~ ><br />
</pre><br />
<br><br />
What did we do? We generated a 1024 bit long (<code>-b 1024</code>) public/private dsa (<code>-t dsa</code>) key pair with the <code>ssh-keygen</code> command. You can also create a rsa key (<code>-t rsa</code>). You can leave out the bit length parameter (default bit length is 1024).<br><br />
In case you don't like the standard key name you can specify a name using the <code>-f name</code> parameter.<br><br />
In the process you are asked for a place to save your keys. I kept the standard path. Then you are asked for a passphrase. <br><br />
Now there are two paths which you can follow or ''"Choose your destiny"'' (as the guy from Mortal Kombat would say):<br><br />
'''a)''' ''the short, easy but insecure way'': use no passphrase, have easy access to your remote-server, feel paranoid about someone stealing your private key<br><br />
'''b)''' ''the a bit longer, slightly less comfortable but secure way'': use a passphrase, use ssh-agent and feel safe<br />
<br />
====Step 2: copy your public key to the remote server {SAME for path A and B}====<br />
<pre><br />
mith@middleearth||[[~]]:~ > scp .ssh/id_dsa.pub mith@metawire.org:<br />
</pre><br />
<br><br />
Copy the public key (<code>id_dsa.pub</code>) to your remote server via scp (note the '''<code>:</code>''' at the end of the server address. That way the file actually ends up in our server home directory but you can specify another path if you like.<br><br />
<br />
====Step 2+3 - The easy way====<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-copy-id -i .ssh/id_dsa.pub mith@metawire.org<br />
</pre><br />
DONE!<br />
<br />
====Step 3: login to the remote computer and put your key into the right place {SAME for path A and B}====<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh metawire.org<br />
mith@metawire.org's password:<br />
-bash-2.05b$ mkdir .ssh/<br />
-bash-2.05b$ cat id_dsa.pub >> .ssh/authorized_keys<br />
-bash-2.05b$ rm id_dsa.pub<br />
-bash-2.05b$ chmod 700 .ssh<br />
-bash-2.05b$ chmod 600 .ssh/authorized_keys<br />
</pre><br />
<br><br />
We connect to our remote server and use cat to add the content of <code>id_dsa.pub</code> to <code>authorized_keys</code> which is in the hidden directory <code>.ssh</code>. ''NOTE:'' In case you get an error because the <code>.ssh</code> directory doesn't exist you should simply create it (<code>mkdir .ssh</code>).<br><br />
Now we remove the public key (<code>rm id_dsa.pub</code>) and set the correct permissions for <code>.ssh</code> and <code>authorized_keys</code>.<br><br />
Log out and re-login. Depending on the path you chose, you will/won't be asked for a passphrase. '''Path a ends here...'''<br />
<br><br />
<br />
====...path b continues...====<br />
Now what makes this path almost as easy as a no-passphrase key? The magic word is ssh-agent.. What it does is basically asking you once every session for the passphrase of your private key and every time you would have to type it in, <code>ssh-agent</code> does it for you. <code>ssh-agent</code> is included in the <code>openssh</code> package so no trouble there...<br><br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-agent<br />
SSH_AUTH_SOCK=/tmp/ssh-vEGjCM2147/agent.2147; export SSH_AUTH_SOCK;<br />
SSH_AGENT_PID=2148; export SSH_AGENT_PID;<br />
echo Agent pid 2148;<br />
</pre><br />
<br><br />
When you run <code>ssh-agent</code> it will print out what environment variables it would use... Well to make <code>ssh-agent</code> use these variables run<br />
<pre><br />
mith@middleearth||[[~]]:~ > eval `ssh-agent`<br />
Agent pid 2157<br />
</pre><br />
The process id will vary for you of course. Adding <code>eval `ssh-agent`</code> to your <code>.bashrc</code> is an option so it's started every time you create a new shell.<br><br />
Now that the <code>ssh-agent</code> is running, we need to tell it that we have a private key and where that is.<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-add .ssh/id_dsa<br />
Enter passphrase for .ssh/id_dsa:<br />
Identity added: .ssh/id_dsa (.ssh/id_dsa)<br />
</pre><br />
<br><br />
We were asked for our passphrase, entered it, that's all. Now you can login to your remote server without having to enter your password while your private key is password-protected. Sweet isn't it? The only downside is that a new instance of <code>ssh-agent</code> needs to be created for every new console (shell) you open, that means you have to run <code>ssh-add</code> every time again on each console. There is a workaround to that with a program or rather a script called [http://www.gentoo.org/proj/en/keychain/index.xml keychain] which is covered in the next section.<br />
<br />
====Using keychain====<br />
[http://www.gentoo.org/proj/en/keychain/index.xml Keychain] manages one or more specified private keys. When initialized it will ask for the passphrase for the private key(s) and store it. That way your private key is password protected but you won't have to enter your password over and over again.<br />
<br />
Install keychain from the extra repo:<br />
# pacman -S keychain<br />
Edit your <code>~/.bashrc</code> and add the following lines:<br />
<pre><br />
/usr/bin/keychain -Q -q ~/.ssh/id_dsa<br />
[[ -f $HOME/.keychain/$HOSTNAME-sh ]] && source $HOME/.keychain/$HOSTNAME-sh<br />
</pre><br />
If necessary, replace <code>~/.ssh/id_dsa</code> with <code>~/.ssh/id_rsa</code>. For those using a non-Bash shell, see <code>keychain --help</code> or <code>man keychain</code> for details on other shells.<br />
<br />
Close your shell and open it again. Keychain should come up and if it's your first run it will ask your for the passphrase of the specified private key.<br />
<br />
====Using ssh-agent and x11-ssh-askpass====<br />
You need to start the ssh-agent everytime you start a new Xsession. The ssh-agent will be closed when the X session ends.<br><br />
Install x11-ssh-askpass which will ask your passphrase everytime you open a new Xsession:<br><br />
<code>sudo pacman -S x11-ssh-askpass</code><br />
<br />
Prepend this into your <code>~/.xsession</code> :<br />
<pre><br />
eval `/usr/bin/ssh-agent`<br />
SSH_ASKPASS=/usr/lib/openssh/x11-ssh-askpass ssh-add < /dev/null<br />
# then the end of the file with for example "exec dwm"<br />
</pre><br />
<br />
====SSH connection control====<br />
In ~/.ssh/config, add the following lines: <br />
host *<br />
controlmaster auto<br />
controlpath /tmp/ssh-%r@%h:%p<br />
What this does is set a "master control" socket when you make an SSH connection. The socket is named based on the <code>controlpath</code> setting (<code>%r</code> = username, <code>%h</code> = hostname, <code>%p</code> = port). <br />
<br />
This master socket is used for each successive connection after the first, as long as one connection still exists. That is, if you connect via <code>ssh myuser@myhost.com</code>, a socket named <code>/tmp/ssh-myuser@myhost.com:22</code> is created. If you then ssh again to the same host, the socket is found and the remote ssh session is told to spawn a new shell. This shell does not require a login, and spawns immediately, as you're already logged in.<br />
<br />
<br />
===PuTTY===<br />
The above procedure is a bit complicated when using PuTTY on Windows since PuTTY can't directly use keys generated by ssh-keygen. The private key needs to be converted using PuTTYgen which you can find [http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html here]. The procedure is then as follows:<br />
#Generate the key pair with ssh-keygen on you Linux computer (you can log in with your usual username/password using PuTTY)<br />
#Add the public key to the ''~/.ssh/authorized_keys'' file<br />
#Move the private key to the Windows machine<br />
#Load the private key with PuTTYgen and click ''Save private key''. This will convert the key so that PuTTY can use it.<br />
#Start PuTTY, go to ''SSH''->''Auth'' and find the private key. Then simply connect to your Linux machine. You will be prompted for your username and passphrase (if you chose to enter one when you generated the keys).<br />
Note that reversing the procedure, that is, generating the key pair with PuTTYgen and converting the public key with ssh-keygen, will NOT work.<br />
<br />
<br />
===Useful links / information===<br />
* [http://www.puddingonline.com/~dave/publications/SSH-with-Keys-HOWTO/document/html-one-page/SSH-with-Keys-HOWTO.html SSH with Keys HOWTO]<br />
* [http://www.arches.uga.edu/~pkeck/ssh/ HOWTO: set up ssh keys]<br />
<!-- Not Found + [http://particle.phys.uvic.ca/doc_sshkey.html ] --><br />
* [http://www-106.ibm.com/developerworks/linux/library/l-keyc.html OpenSSH key management, Part 1]<br />
* [http://www-106.ibm.com/developerworks/linux/library/l-keyc2/ OpenSSH key management, Part 2]<br />
* [http://www-106.ibm.com/developerworks/library/l-keyc3/ OpenSSH key management, Part 3]<br />
* [http://kimmo.suominen.com/docs/ssh/ Getting started with SSH]<br />
* Manual Pages: [http://www.openbsd.org/cgi-bin/man.cgi?query=ssh-keygen&apropos=0&sektion=0&manpath=OpenBSD+Current&arch=i386&format=html ssh-keygen(1)]<br />
* [http://blog.eukhost.com/2006/11/24/sharing-ssh-keys-on-2-linux-servers-to-login-without-authentication/ Sharing SSH keys on 2 linux servers]<br />
* [http://www.andremolnar.com/how_to_set_up_ssh_keys_with_putty_and_not_get_server_refused_our_key How to set up SSH keys: Frustration with "Server refused our key" [PuTTY]]<br />
* [http://blog.webhosting.uk.com/2007/04/01/securing-your-secure-shell-ssh-service/ Securing your secure shell (SSH) service]</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=SSH_keys&diff=52845SSH keys2008-11-07T12:50:06Z<p>Tkjacobsen: /* Step 2: copy your public key to the remote server {SAME for path A and B} */</p>
<hr />
<div>[[Category:Networking (English)]]<br />
[[Category:Security (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Using_SSH_Keys}}<br />
{{i18n_entry|Русский|Использование_SSH_ключей}}<br />
{{i18n_links_end}}<br />
<br />
===Using SSH-keys to connect to a server===<br />
====Why use those keys?====<br />
Using ssh-keys, a public and a private key to be precise, is an easy way to connect to a server/a whole bunch of servers, using the same password ''OR'' using no password at all. You should prefer the password/ssh-agent combination!<br><br />
<br />
====Step 1: generate the keys====<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-keygen -b 1024 -t dsa<br />
Generating public/private dsa key pair.<br />
Enter file in which to save the key (/home/mith/.ssh/id_dsa):<br />
Enter passphrase (empty for no passphrase):<br />
Enter same passphrase again:<br />
Your identification has been saved in /home/mith/.ssh/id_dsa.<br />
Your public key has been saved in /home/mith/.ssh/id_dsa.pub.<br />
The key fingerprint is:<br />
x6:68:xx:93:98:8x:87:95:7x:2x:4x:x9:81:xx:56:94 mith@middleearth<br />
mith@middleearth||[[~]]:~ ><br />
</pre><br />
<br><br />
What did we do? We generated a 1024 bit long (<code>-b 1024</code>) public/private dsa (<code>-t dsa</code>) key pair with the <code>ssh-keygen</code> command. You can also create a rsa key (<code>-t rsa</code>). You can leave out the bit length parameter (default bit length is 1024).<br><br />
In case you don't like the standard key name you can specify a name using the <code>-f name</code> parameter.<br><br />
In the process you are asked for a place to save your keys. I kept the standard path. Then you are asked for a passphrase. <br><br />
Now there are two paths which you can follow or ''"Choose your destiny"'' (as the guy from Mortal Kombat would say):<br><br />
'''a)''' ''the short, easy but insecure way'': use no passphrase, have easy access to your remote-server, feel paranoid about someone stealing your private key<br><br />
'''b)''' ''the a bit longer, slightly less comfortable but secure way'': use a passphrase, use ssh-agent and feel safe<br />
<br />
====Step 2: copy your public key to the remote server {SAME for path A and B}====<br />
<pre><br />
mith@middleearth||[[~]]:~ > scp .ssh/id_dsa.pub mith@metawire.org:<br />
</pre><br />
<br><br />
Copy the public key (<code>id_dsa.pub</code>) to your remote server via scp (note the '''<code>:</code>''' at the end of the server address. That way the file actually ends up in our server home directory but you can specify another path if you like.<br><br />
<br />
==Step 2+3 - The easy way==<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-copy-id .ssh/id_dsa.pub mith@metawire.org<br />
</pre><br />
DONE!<br />
<br />
====Step 3: login to the remote computer and put your key into the right place {SAME for path A and B}====<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh metawire.org<br />
mith@metawire.org's password:<br />
-bash-2.05b$ mkdir .ssh/<br />
-bash-2.05b$ cat id_dsa.pub >> .ssh/authorized_keys<br />
-bash-2.05b$ rm id_dsa.pub<br />
-bash-2.05b$ chmod 700 .ssh<br />
-bash-2.05b$ chmod 600 .ssh/authorized_keys<br />
</pre><br />
<br><br />
We connect to our remote server and use cat to add the content of <code>id_dsa.pub</code> to <code>authorized_keys</code> which is in the hidden directory <code>.ssh</code>. ''NOTE:'' In case you get an error because the <code>.ssh</code> directory doesn't exist you should simply create it (<code>mkdir .ssh</code>).<br><br />
Now we remove the public key (<code>rm id_dsa.pub</code>) and set the correct permissions for <code>.ssh</code> and <code>authorized_keys</code>.<br><br />
Log out and re-login. Depending on the path you chose, you will/won't be asked for a passphrase. '''Path a ends here...'''<br />
<br><br />
<br />
====...path b continues...====<br />
Now what makes this path almost as easy as a no-passphrase key? The magic word is ssh-agent.. What it does is basically asking you once every session for the passphrase of your private key and every time you would have to type it in, <code>ssh-agent</code> does it for you. <code>ssh-agent</code> is included in the <code>openssh</code> package so no trouble there...<br><br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-agent<br />
SSH_AUTH_SOCK=/tmp/ssh-vEGjCM2147/agent.2147; export SSH_AUTH_SOCK;<br />
SSH_AGENT_PID=2148; export SSH_AGENT_PID;<br />
echo Agent pid 2148;<br />
</pre><br />
<br><br />
When you run <code>ssh-agent</code> it will print out what environment variables it would use... Well to make <code>ssh-agent</code> use these variables run<br />
<pre><br />
mith@middleearth||[[~]]:~ > eval `ssh-agent`<br />
Agent pid 2157<br />
</pre><br />
The process id will vary for you of course. Adding <code>eval `ssh-agent`</code> to your <code>.bashrc</code> is an option so it's started every time you create a new shell.<br><br />
Now that the <code>ssh-agent</code> is running, we need to tell it that we have a private key and where that is.<br />
<pre><br />
mith@middleearth||[[~]]:~ > ssh-add .ssh/id_dsa<br />
Enter passphrase for .ssh/id_dsa:<br />
Identity added: .ssh/id_dsa (.ssh/id_dsa)<br />
</pre><br />
<br><br />
We were asked for our passphrase, entered it, that's all. Now you can login to your remote server without having to enter your password while your private key is password-protected. Sweet isn't it? The only downside is that a new instance of <code>ssh-agent</code> needs to be created for every new console (shell) you open, that means you have to run <code>ssh-add</code> every time again on each console. There is a workaround to that with a program or rather a script called [http://www.gentoo.org/proj/en/keychain/index.xml keychain] which is covered in the next section.<br />
<br />
====Using keychain====<br />
[http://www.gentoo.org/proj/en/keychain/index.xml Keychain] manages one or more specified private keys. When initialized it will ask for the passphrase for the private key(s) and store it. That way your private key is password protected but you won't have to enter your password over and over again.<br />
<br />
Install keychain from the extra repo:<br />
# pacman -S keychain<br />
Edit your <code>~/.bashrc</code> and add the following lines:<br />
<pre><br />
/usr/bin/keychain -Q -q ~/.ssh/id_dsa<br />
[[ -f $HOME/.keychain/$HOSTNAME-sh ]] && source $HOME/.keychain/$HOSTNAME-sh<br />
</pre><br />
If necessary, replace <code>~/.ssh/id_dsa</code> with <code>~/.ssh/id_rsa</code>. For those using a non-Bash shell, see <code>keychain --help</code> or <code>man keychain</code> for details on other shells.<br />
<br />
Close your shell and open it again. Keychain should come up and if it's your first run it will ask your for the passphrase of the specified private key.<br />
<br />
====Using ssh-agent and x11-ssh-askpass====<br />
You need to start the ssh-agent everytime you start a new Xsession. The ssh-agent will be closed when the X session ends.<br><br />
Install x11-ssh-askpass which will ask your passphrase everytime you open a new Xsession:<br><br />
<code>sudo pacman -S x11-ssh-askpass</code><br />
<br />
Prepend this into your <code>~/.xsession</code> :<br />
<pre><br />
eval `/usr/bin/ssh-agent`<br />
SSH_ASKPASS=/usr/lib/openssh/x11-ssh-askpass ssh-add < /dev/null<br />
# then the end of the file with for example "exec dwm"<br />
</pre><br />
<br />
====SSH connection control====<br />
In ~/.ssh/config, add the following lines: <br />
host *<br />
controlmaster auto<br />
controlpath /tmp/ssh-%r@%h:%p<br />
What this does is set a "master control" socket when you make an SSH connection. The socket is named based on the <code>controlpath</code> setting (<code>%r</code> = username, <code>%h</code> = hostname, <code>%p</code> = port). <br />
<br />
This master socket is used for each successive connection after the first, as long as one connection still exists. That is, if you connect via <code>ssh myuser@myhost.com</code>, a socket named <code>/tmp/ssh-myuser@myhost.com:22</code> is created. If you then ssh again to the same host, the socket is found and the remote ssh session is told to spawn a new shell. This shell does not require a login, and spawns immediately, as you're already logged in.<br />
<br />
<br />
===PuTTY===<br />
The above procedure is a bit complicated when using PuTTY on Windows since PuTTY can't directly use keys generated by ssh-keygen. The private key needs to be converted using PuTTYgen which you can find [http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html here]. The procedure is then as follows:<br />
#Generate the key pair with ssh-keygen on you Linux computer (you can log in with your usual username/password using PuTTY)<br />
#Add the public key to the ''~/.ssh/authorized_keys'' file<br />
#Move the private key to the Windows machine<br />
#Load the private key with PuTTYgen and click ''Save private key''. This will convert the key so that PuTTY can use it.<br />
#Start PuTTY, go to ''SSH''->''Auth'' and find the private key. Then simply connect to your Linux machine. You will be prompted for your username and passphrase (if you chose to enter one when you generated the keys).<br />
Note that reversing the procedure, that is, generating the key pair with PuTTYgen and converting the public key with ssh-keygen, will NOT work.<br />
<br />
<br />
===Useful links / information===<br />
* [http://www.puddingonline.com/~dave/publications/SSH-with-Keys-HOWTO/document/html-one-page/SSH-with-Keys-HOWTO.html SSH with Keys HOWTO]<br />
* [http://www.arches.uga.edu/~pkeck/ssh/ HOWTO: set up ssh keys]<br />
<!-- Not Found + [http://particle.phys.uvic.ca/doc_sshkey.html ] --><br />
* [http://www-106.ibm.com/developerworks/linux/library/l-keyc.html OpenSSH key management, Part 1]<br />
* [http://www-106.ibm.com/developerworks/linux/library/l-keyc2/ OpenSSH key management, Part 2]<br />
* [http://www-106.ibm.com/developerworks/library/l-keyc3/ OpenSSH key management, Part 3]<br />
* [http://kimmo.suominen.com/docs/ssh/ Getting started with SSH]<br />
* Manual Pages: [http://www.openbsd.org/cgi-bin/man.cgi?query=ssh-keygen&apropos=0&sektion=0&manpath=OpenBSD+Current&arch=i386&format=html ssh-keygen(1)]<br />
* [http://blog.eukhost.com/2006/11/24/sharing-ssh-keys-on-2-linux-servers-to-login-without-authentication/ Sharing SSH keys on 2 linux servers]<br />
* [http://www.andremolnar.com/how_to_set_up_ssh_keys_with_putty_and_not_get_server_refused_our_key How to set up SSH keys: Frustration with "Server refused our key" [PuTTY]]<br />
* [http://blog.webhosting.uk.com/2007/04/01/securing-your-secure-shell-ssh-service/ Securing your secure shell (SSH) service]</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=51398HP Compaq nc44002008-10-18T08:43:11Z<p>Tkjacobsen: /* Xorg configuration */</p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
Bluetooth works (kdebluetooth, but probably also gnome-bluetooth).<br />
<br />
Cpu frequency scaling works. (cpufrequtils with the p4_clockmod module).<br />
<br />
==Xorg configuration==<br />
The i810 driver works for graphics (and the intel driver, but I (Tkjacobsen) find it buggy with composite (not anymore))<br />
<pre><br />
pacman -S xf86-video-intel<br />
</pre><br />
<br />
Use [[Touchpad_Synaptics]] to tune the touthpad.<br />
<br />
==Wifi==<br />
The iwlwifi drivers works (also with (k)networkmanager).<br />
<br />
<pre><br />
pacman -S iwlwifi-3945-ucode<br />
modprobe iwl3945<br />
</pre><br />
And put '''iwl3945''' in your MODULES array.<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
==HDD failing sensors==<br />
See the [[Smart]] howto.<br />
This line in /etc/smartd.conf does the job for me (Tkjacobsen):<br />
<pre><br />
/dev/sda -a -d sat -m root@localhost<br />
</pre> <br />
<br />
===ToDo===<br />
* The fingerprint reader is via USB, haven't looked into that yet either.<br />
<br />
=External links=<br />
[http://gentoo-wiki.com/HARDWARE_Gentoo_on_HP_Compaq_nc4400 Gentoo Wiki]</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=51397HP Compaq nc44002008-10-18T08:36:50Z<p>Tkjacobsen: /* Xorg configuration */</p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
Bluetooth works (kdebluetooth, but probably also gnome-bluetooth).<br />
<br />
Cpu frequency scaling works. (cpufrequtils with the p4_clockmod module).<br />
<br />
==Xorg configuration==<br />
The i810 driver works for graphics (and the intel driver, but I (Tkjacobsen) find it buggy with composite)<br />
<pre><br />
pacman -S xf86-video-intel<br />
</pre><br />
<br />
Use [[Touchpad_Synaptics]] to tune the touthpad.<br />
<br />
==Wifi==<br />
The iwlwifi drivers works (also with (k)networkmanager).<br />
<br />
<pre><br />
pacman -S iwlwifi-3945-ucode<br />
modprobe iwl3945<br />
</pre><br />
And put '''iwl3945''' in your MODULES array.<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
==HDD failing sensors==<br />
See the [[Smart]] howto.<br />
This line in /etc/smartd.conf does the job for me (Tkjacobsen):<br />
<pre><br />
/dev/sda -a -d sat -m root@localhost<br />
</pre> <br />
<br />
===ToDo===<br />
* The fingerprint reader is via USB, haven't looked into that yet either.<br />
<br />
=External links=<br />
[http://gentoo-wiki.com/HARDWARE_Gentoo_on_HP_Compaq_nc4400 Gentoo Wiki]</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=33622HP Compaq nc44002007-12-15T09:27:31Z<p>Tkjacobsen: </p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
Bluetooth works (kdebluetooth, but probably also gnome-bluetooth).<br />
<br />
Cpu frequency scaling works. (cpufrequtils with the p4_clockmod module).<br />
<br />
==Xorg configuration==<br />
The i810 driver works for graphics (and the intel driver, but I (Tkjacobsen) find it buggy with composite)<br />
<pre><br />
pacman -S xf86-video-i810<br />
</pre><br />
<br />
Use [[Touchpad_Synaptics]] to tune the touthpad.<br />
<br />
==Wifi==<br />
The iwlwifi drivers works (also with (k)networkmanager).<br />
<br />
<pre><br />
pacman -S iwlwifi iwlwifi-3945-ucode<br />
modprobe iwl3945<br />
</pre><br />
Or put it in your MODULES line.<br />
<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
==HDD failing sensors==<br />
See the [[Smart]] howto.<br />
This line in /etc/smartd.conf does the job for me (Tkjacobsen):<br />
<pre><br />
/dev/sda -a -d sat -m root@localhost<br />
</pre> <br />
<br />
===ToDo===<br />
* The HDD has falling sensors to prevent damage. Haven't looked into it yet.<br />
* The fingerprint reader is via USB, haven't looked into that yet either.<br />
<br />
<br />
=External links=<br />
[http://gentoo-wiki.com/HARDWARE_Gentoo_on_HP_Compaq_nc4400 Gentoo Wiki]</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=32989HP Compaq nc44002007-12-02T12:03:48Z<p>Tkjacobsen: /* What works/What doesn't */</p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
Bluetooth works (kdebluetooth, but probably also gnome-bluetooth).<br />
<br />
Cpu frequency scaling works. (cpufrequtils with the p4_clockmod module).<br />
<br />
==Xorg configuration==<br />
The i810 driver works for graphics (and the intel driver, but I (Tkjacobsen) find it buggy with composite)<br />
<pre><br />
pacman -S xf86-video-i810<br />
</pre><br />
<br />
Use [[Touchpad_Synaptics]] to tune the touthpad.<br />
<br />
==Wifi==<br />
The iwlwifi drivers works (also with (k)networkmanager).<br />
<br />
<pre><br />
pacman -S iwlwifi iwlwifi-3945-ucode<br />
modprobe iwl3945<br />
</pre><br />
Or put it in your MODULES line.<br />
<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
==HDD failing sensors==<br />
See the [[Smart]] howto.<br />
This line in /etc/smartd.conf does the job for me (Tkjacobsen):<br />
<pre><br />
/dev/sda -a -d sat -m root@localhost<br />
</pre> <br />
<br />
===ToDo===<br />
* The HDD has falling sensors to prevent damage. Haven't looked into it yet.<br />
* The fingerprint reader is via USB, haven't looked into that yet either.</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=32988HP Compaq nc44002007-12-02T12:03:33Z<p>Tkjacobsen: /* What works/What doesn't */</p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
Bluetooth works (kdebluetooth, but probably also gnome-bluetooth).<br />
Cpu frequency scaling works. (cpufrequtils with the p4_clockmod module).<br />
<br />
==Xorg configuration==<br />
The i810 driver works for graphics (and the intel driver, but I (Tkjacobsen) find it buggy with composite)<br />
<pre><br />
pacman -S xf86-video-i810<br />
</pre><br />
<br />
Use [[Touchpad_Synaptics]] to tune the touthpad.<br />
<br />
==Wifi==<br />
The iwlwifi drivers works (also with (k)networkmanager).<br />
<br />
<pre><br />
pacman -S iwlwifi iwlwifi-3945-ucode<br />
modprobe iwl3945<br />
</pre><br />
Or put it in your MODULES line.<br />
<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
==HDD failing sensors==<br />
See the [[Smart]] howto.<br />
This line in /etc/smartd.conf does the job for me (Tkjacobsen):<br />
<pre><br />
/dev/sda -a -d sat -m root@localhost<br />
</pre> <br />
<br />
===ToDo===<br />
* The HDD has falling sensors to prevent damage. Haven't looked into it yet.<br />
* The fingerprint reader is via USB, haven't looked into that yet either.</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=32987HP Compaq nc44002007-12-02T12:00:33Z<p>Tkjacobsen: /* Xorg configuration */</p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
==Xorg configuration==<br />
The i810 driver works for graphics (and the intel driver, but I (Tkjacobsen) find it buggy with composite)<br />
<pre><br />
pacman -S xf86-video-i810<br />
</pre><br />
<br />
Use [[Touchpad_Synaptics]] to tune the touthpad.<br />
<br />
==Wifi==<br />
The iwlwifi drivers works (also with (k)networkmanager).<br />
<br />
<pre><br />
pacman -S iwlwifi iwlwifi-3945-ucode<br />
modprobe iwl3945<br />
</pre><br />
Or put it in your MODULES line.<br />
<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
==HDD failing sensors==<br />
See the [[Smart]] howto.<br />
This line in /etc/smartd.conf does the job for me (Tkjacobsen):<br />
<pre><br />
/dev/sda -a -d sat -m root@localhost<br />
</pre> <br />
<br />
===ToDo===<br />
* The HDD has falling sensors to prevent damage. Haven't looked into it yet.<br />
* The fingerprint reader is via USB, haven't looked into that yet either.</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=32986HP Compaq nc44002007-12-02T11:57:21Z<p>Tkjacobsen: Xorg configuration</p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
==Xorg configuration==<br />
The i810 driver works for graphics (and the intel driver, but i find it buggy with composite)<br />
<pre><br />
pacman -S xf86-video-i810<br />
</pre><br />
<br />
Use [[Touchpad_Synaptics]] to tune the touthpad.<br />
<br />
<br />
==Wifi==<br />
The iwlwifi drivers works (also with (k)networkmanager).<br />
<br />
<pre><br />
pacman -S iwlwifi iwlwifi-3945-ucode<br />
modprobe iwl3945<br />
</pre><br />
Or put it in your MODULES line.<br />
<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
==HDD failing sensors==<br />
See the [[Smart]] howto.<br />
This line in /etc/smartd.conf does the job for me (Tkjacobsen):<br />
<pre><br />
/dev/sda -a -d sat -m root@localhost<br />
</pre> <br />
<br />
===ToDo===<br />
* The HDD has falling sensors to prevent damage. Haven't looked into it yet.<br />
* The fingerprint reader is via USB, haven't looked into that yet either.</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=32985HP Compaq nc44002007-12-02T11:50:25Z<p>Tkjacobsen: </p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
==Wifi==<br />
The iwlwifi drivers works (also with (k)networkmanager).<br />
<br />
<pre><br />
pacman -S iwlwifi iwlwifi-3945-ucode<br />
modprobe iwl3945<br />
</pre><br />
Or put it in your MODULES line.<br />
<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
==HDD failing sensors==<br />
See the [[Smart]] howto.<br />
This line in /etc/smartd.conf does the job for me (Tkjacobsen):<br />
<pre><br />
/dev/sda -a -d sat -m root@localhost<br />
</pre> <br />
<br />
===ToDo===<br />
* The HDD has falling sensors to prevent damage. Haven't looked into it yet.<br />
* The fingerprint reader is via USB, haven't looked into that yet either.</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=32984HP Compaq nc44002007-12-02T11:44:43Z<p>Tkjacobsen: HDD failing sensors</p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
==HDD failing sensors==<br />
See the [[Smart]] howto.<br />
This line in /etc/smartd.conf does the job for me (Tkjacobsen):<br />
<pre><br />
/dev/sda -a -d sat -m root@localhost<br />
</pre> <br />
<br />
===ToDo===<br />
* The HDD has falling sensors to prevent damage. Haven't looked into it yet.<br />
* The fingerprint reader is via USB, haven't looked into that yet either.</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=32983HP Compaq nc44002007-12-02T11:38:49Z<p>Tkjacobsen: /* ToDo */</p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
===ToDo===<br />
<br />
* The HDD has falling sensors to prevent damage. Haven't looked into it yet.<br />
* The fingerprint reader is via USB, haven't looked into that yet either.</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=HP_Compaq_nc4400&diff=32982HP Compaq nc44002007-12-02T11:38:28Z<p>Tkjacobsen: </p>
<hr />
<div>[[Category:Laptops (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{stub}}<br />
==Introduction==<br />
I wanted a small and fast laptop that's capable of running Linux. My choice is a HP Compaq nc4400 since the Lenovo Thinkpad X-serie is too expensive. <br />
This HP and the Lenovo Thinkpad have a lot in common, for example they both sport a pointing stick and both lack an optical (cd/dvd) drive. <br />
My goal was to leave the pre-installed WinXP on the laptop and install Arch from an usb stick since I don't own an USB cd/dvd drive. <br />
<br />
===System Specifications===<br />
<br />
HP Compaq nc4400 - Centrino Duo<br />
* Intel Core 2 Duo T5600, 2x1.83GHz (Speedstep, 667MHz FSB, 2MB L3) (VT support can be enabled in the BIOS)<br />
* Mobile Intel 945GM Express Chipset (ICH7 Family)<br />
* 2x512MB 667MHz DDR2 SDRAM<br />
* 80GB 2.5" 5400rpm Fujitsu-Siemens SATA HDD<br />
* 12" 1024x768 TFT<br />
* Intel Graphics Media Accelerator 945GM<br />
* Intel HDA audio<br />
* 56K Fax/Modem<br />
* Broadcom NetXtreme Gigabit Ethernet (BCM5753M)<br />
* 3xUSB2.0, one giving a full ampere of power<br />
* Intel 3945ABG <br />
* Bluetooth (Broadcom)<br />
* TI SD/MMC Memory Card reader<br />
* Fingerprint reader (AuthenTec)<br />
* Infineon TPM and Smartcard reader<br />
* IRdA<br />
* VGA and Svideo for an external monitor/television<br />
* 52W - 4698mAh battery (4-5h)<br />
* Synaptics Touchpad and a pointing stick!<br />
* One cardbus slot<br />
* 65W adapter<br />
* Ambient Light Sensor<br />
<br />
lshwd output: <br />
<br />
* 00:00.0 Class 0600: Intel Corp.|Mobile Memory Controller Hub (intel-agp)<br />
* 00:02.0 Class 0300: Intel Corp.|Mobile Integrated Graphics Controller (i810)<br />
* 00:02.1 Class 0380: Intel Corp.|Mobile Integrated Graphics Controller (vesa)<br />
* 00:1b.0 Class 0403: Intel Corp.|I/O Controller Hub High Definition Audio (snd-hda-intel)<br />
* 00:1c.0 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 1 (unknown)<br />
* 00:1c.1 Class 0604: Intel Corp.|I/O Controller Hub PCI Express Port 2 (unknown)<br />
* 00:1d.0 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #1 (unknown)<br />
* 00:1d.1 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #2 (unknown)<br />
* 00:1d.2 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #3 (unknown)<br />
* 00:1d.3 Class 0c03: Intel Corp.|I/O Controller Hub UHCI USB #4 (unknown)<br />
* 00:1d.7 Class 0c03: Intel Corp.|I/O Controller Hub EHCI USB (unknown)<br />
* 00:1e.0 Class 0604: Intel Corp.|82801 Hub Interface to PCI Bridge (hw_random)<br />
* 00:1f.0 Class 0601: Intel Corp.|Mobile I/O Controller Hub LPC (i8xx_tco)<br />
* 00:1f.1 Class 0101: Intel Corp.|I/O Controller Hub PATA (piix)<br />
* 00:1f.2 Class 0106: Intel Corp.|Mobile I/O Controller Hub SATA cc=AHCI (ahci)<br />
* 02:06.0 Class 0607: Texas Instruments|PCIxx12 CardBus Controller (yenta_socket)<br />
* 02:06.2 Class 0180: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.3 Class 0805: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 02:06.4 Class 0780: Texas Instruments|5-in-1 Multimedia Card Reader (SD/MMC/MS/MS PRO/xD) (unknown)<br />
* 08:00.0 Class 0200: Broadcom Corp.|NetXtreme BCM5753M Gigabit Ethernet PCI Express (tg3)<br />
* 10:00.0 Class 0280: Intel Corporation|PRO/Wireless 3945ABG (ipw3945)<br />
* ---:--- Mouse: Generic PS/2 Wheel Mouse [/dev/psaux] (msintellips/2)<br />
<br />
===What works/What doesn't===<br />
<br />
Pretty much everything needed works when you tweak. This wiki is an excellent source of infomation. :)<br />
On windows the network controller (nextreme) can be "safely removed" to save power. I think you can do the same in linux with "rmmod tg3". <br />
<br />
For the right console display size I set vga=792 (1024x768x16M@60Hz) as a kernel boot parameter.<br />
<br />
There's hardware mute and volume up/down buttons. They work but odly every time I reboot it's always back to mute. More like a feature than a bug.<br />
<br />
The fn+brighter/dimmer display buttons and the Ambient Light Sensor work software independent.<br />
<br />
In my understanding, the TPM doesn't show anywhere even tho there's a kernel module for the infineon TPM. I haven't tried to make it work and probably won't even try.<br />
I believe the Irda and modem work as expected, haven't tested.<br />
<br />
I haven't tried to use an external monitor/TV, I expect making those work is just matter of confing.<br />
<br />
The ICH7 family sports a hpet multimedia timer that saves power. Kernel boot parameter hpet=force just in case.<br />
<br />
==SD/MMC memory card reader==<br />
This works with the tifm driver.<br />
<pre><br />
modprobe tifm_core<br />
modprobe tifm_7xx1<br />
modprobe tifm_sd<br />
</pre><br />
Or you can put them in the MODULES array in /etc/rc.conf<br />
<br />
===ToDo===<br />
<br />
* The HDD has falling sensors to prevent damage. Haven't looked into it yet.<br />
* The fingerprint reader is via USB, haven't looked into that yet either.<br />
* SD/MMC memory card reader. It's TI's so it might work.</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=GRUB_Legacy&diff=32657GRUB Legacy2007-11-22T10:45:16Z<p>Tkjacobsen: Corrected a wrong path</p>
<hr />
<div>[[Category:Boot process (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|GRUB}}<br />
{{i18n_entry|עברית|GRUB (עברית)}}<br />
{{i18n_entry|简体中文|GRUB(简体中文)}}<br />
{{i18n_entry|Русский|GRUB (Русский)}}<br />
{{i18n_links_end}}<br />
GRand Unified Bootloader (GRUB)<br />
<br />
== Installing Grub package ==<br />
<br />
First install grub with pacman<br />
<br />
<br />
pacman -Sy grub<br />
<br />
<br />
Edit the menu.lst with your settings<br />
<br />
<br />
nano /boot/grub/menu.lst<br />
<br />
<br />
''Note: Use hd[a-z] for ide and sd[a-z] for scsi and sata''<br />
<br />
Here is mine for example:<br />
<br />
<br />
# Config file for GRUB - The GNU GRand Unified Bootloader<br />
# /boot/grub/menu.lst<br />
<br />
# DEVICE NAME CONVERSIONS <br />
#<br />
# Linux Grub<br />
# -------------------------<br />
# /dev/fd0 (fd0)<br />
# /dev/hda (hd0)<br />
# /dev/hdb2 (hd1,1)<br />
# /dev/hda3 (hd0,2)<br />
#<br />
<br />
# FRAMEBUFFER RESOLUTION SETTINGS<br />
# +-------------------------------------------------+<br />
# | 640x480 800x600 1024x768 1280x1024<br />
# ----+--------------------------------------------<br />
# 256 | 0x301=769 0x303=771 0x305=773 0x307=775<br />
# 32K | 0x310=784 0x313=787 0x316=790 0x319=793<br />
# 64K | 0x311=785 0x314=788 0x317=791 0x31A=794<br />
# 16M | 0x312=786 0x315=789 0x318=792 0x31B=795<br />
# +-------------------------------------------------+<br />
<br />
# general configuration:<br />
timeout 5<br />
default 1<br />
color light-blue/black light-cyan/blue<br />
<br />
# boot sections follow<br />
# each is implicitly numbered from 1 in the order of appearance below<br />
#<br />
# TIP: If you want a 1024x768 framebuffer, add "vga=773" to your kernel line.<br />
#<br />
#-*<br />
<br />
# (0) Arch Linux<br />
title Arch Linux [cpio]<br />
root (hd0,0)<br />
kernel /vmlinuz26 root=/dev/sda6 ro vga=773<br />
initrd /kernel26.img<br />
<br />
title Arch Linux [thinkpad]<br />
root (hd0,0)<br />
kernel /vmlinuz26thinkpad root=/dev/sda6 ro video=vesafb:off acpi_sleep=s3_bios<br />
resume2=swap:/dev/sda5<br />
initrd /kernel26thinkpad.img<br />
<br />
<br />
Copy the mounts to mtab<br />
<br />
<br />
grep -v rootfs /proc/mounts > /etc/mtab<br />
<br />
== Installing the boot loader into Master Boot Record ==<br />
Now usually there are two ways to install GRUB. One way is to make a boot disk (on a floppy drive, or cd-rom), and the other way is to install grub directly from a running Arch install. If you are upgrading a version of grub you might want to do the latter because its simpler and faster, but the GRUB website states that doing the boot disk method is safer.<br />
<br />
'''Using the grub-install utility'''<br />
<br />
grub-install -root-directory ''Mount-Point'' (hd''n'') <br />
<br />
Installs grub into the MBR of a hard disc. The option gives the path to the kernel-image, if it is not in /, i.e. in /boot.<br><br />
(hd''n'') is a disc, where n is the number of the disc, starting with 0.<br />
<br />
Example:<br />
<br />
If you have a separate boot partition mounted at ''/boot'', do one of the following<br />
grub-install --root-directory=/boot '(hd0)'<br />
grub-install --root-directory=/boot sda<br />
grub-install --root-directory=/boot hda<br />
<br />
If you don't have a separate boot partition, then just run the command without the ''--root-directory'' option<br />
grub-install /dev/sda<br />
<br />
'''Warning'''<br />
GRUB does not understand the naming schemes hda, sda, etc. It views the disk in terms of (hd0), (hd1), etc.<br />
This is why one ''''must'''' be careful when using grub-install.<br />
<br />
grub-install tries to map the BIOS drives to hda/sda format, and usually it does this correctly. The way to check if this is done correctly is provided by the command after it has finished installing the bootloader. grub-install will print something along the lines of<br />
(fd0) /dev/fd0<br />
(hd0) /dev/hda<br />
You have to check if this mapping is correct. If it is not correct, go to /boot/grub and edit the 'device.map' file so that it is correct. Then ''re-run'' the grub-install utility to reinstall GRUB.<br />
<br />
== Boot loader configuration ==<br />
The grub configuration is done in this file:<br />
/boot/grub/menu.lst<br />
<br />
* <i>(hdn,m)</i> is the partition m on disc n, numbers starting with 0<br />
* <i>splashimage (hdn,m)/grub/Name.xpm.gz</i> is the splash-image-file<br />
* <i>default n</i> is the default boot entry, that is choosen after timout for user action<br />
* <i>timeout m</i> time m to wait in seconds for a user selection, before default is booted<br />
* <i>password -md5 str</i> encrypted boot password 'str'<br />
* <i>title str</i> title string 'str' for a boot entry<br />
* <i>root (hdn,m)</i> base partition, where the kernel is stored to<br />
* <i>kernel /path ro root=/dev/device initrd /initrd.img</i> use the root option, if the kernel not placed in /<br />
* <i>makeactive<br>chainloader +1</i> sets root active and gives booting procedure to its boot-loader (for Windows, f.e.)<br />
* <i>map (hd0) (hd1)<br>map (hd1) (hd0)</i> changes primary and secondary disc for a boot, necessary to boot Windows from a secondary disc<br />
* <i>root (hdn,m,z)<br>kernel /boot/loader</i> boots the FreeBSD-Partition x<br />
* <i>default saved</i> remembers each current boot selection and makes it the new default. Place "savedefault" at the end of each boot section, for that you want this feature shall be used.<br />
<br />
For those who like eye-candy, there is [[Graphical GRUB]].<br />
<br />
<br />
=== Dual booting===<br />
These are the two most common ways of configuring the menu.lst file. For more compex uses, click [[Grub configure examples|here]].<br />
====Dual booting with Windows====<br />
Add this at the end of your /boot/grub/menu.lst. This assumes that your Windows partition is [s/h]da2.<br />
<br />
# (2) Windows XP<br />
title Windows XP<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
====Dual booting with other linux distros====<br />
This is done exactly the same way that Arch linux is loaded. Here we assume that the other distro is on partition [s/h]da3.<br />
title Other Linux<br />
root (hd0,2)<br />
kernel /boot/vmlinuz (add other options here as required)<br />
initrd /boot/initrd.img (if the other kernel uses/needs one)<br />
<br />
=== LiLO and GRUB interaction ===<br />
<br />
If you once had used [[lilo]] Don't forget to remove it with <br />
pacman -R lilo<br />
as some tasks (f.e. kernel compilation using <code>make all</code>) will make a lilo call, and then lilo is installed over grub.<br />
Note that this will not remove lilo from the MBR, but it will be overwritten when you install another bootloader.<br />
<br />
== Troubleshooting==<br />
<br />
* If you are having problems like grub freezing when you do a grub install, use the command abs to get the PKGBUILDS of the arch base packages and then use the command as root:<br />
<br />
cd /var/abs/core/base/grub/<br />
./install-grub<br />
<br />
== External Resources ==<br />
* [http://www.gnu.org/software/grub/ Grub Website]</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=User:Tkjacobsen&diff=31082User:Tkjacobsen2007-10-18T20:16:59Z<p>Tkjacobsen: New page: Name: Troels Kofoed Jacobsen</p>
<hr />
<div>Name: Troels Kofoed Jacobsen</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=S.M.A.R.T.&diff=31046S.M.A.R.T.2007-10-18T07:07:14Z<p>Tkjacobsen: </p>
<hr />
<div>[[Category:HOWTOs (English)]]<br />
=SMART HOWTO=<br />
This page will describe how to setup SMART to monitor your harddisks.<br />
<br />
===Step 1: Install smartmontools===<br />
<pre><br />
pacman -Sy smartmontools<br />
</pre><br />
<br />
===Step 2: Check if your disk(s) support SMART===<br />
IDE-disks:<br />
<pre><br />
smartctl -i /dev/hda<br />
</pre><br />
SATA-disks:<br />
<pre><br />
smartctl -i -d ata /dev/sda<br />
</pre><br />
Look for:<br> <br />
"SMART support is: Available - device has SMART capability."<br><br />
"SMART support is: Enabled"<br><br />
If SMART is NOT enabled you have to do this.<br />
<br />
IDE-disks:<br />
<pre><br />
smartctl -s on /dev/hda<br />
</pre><br />
SATA-discs:<br />
<pre><br />
smartctl -s on -d ata /dev/sda<br />
</pre><br />
<br />
===Step 3: Check your disk(s)===<br />
Check the SMART health status of a device<br />
<pre><br />
smartctl -H /dev/sda<br />
</pre><br />
I all goes well, it will return PASSED. <br />
If the device reports <b>failing health status</b>, this means either that<br />
the device has already failed, or that it is predicting its own<br />
failure within the next 24 hours. If this happens, use the "-a"<br />
option to get more information, and <b>get your data off the disk and<br />
someplace safe as soon as you can</b>.<br />
<br />
Check the SMART Error Log<br />
<pre><br />
smartctl -l error /dev/sda<br />
</pre><br />
If we read No Errors Logged it's ok. If there are a few errors (and they are not so recent) you don't have to worry too much. If there are a lot of errors it's better if you backup your data as soon as you can.<br />
<br />
NOTE: This is not all tests but only two of them. See the manual or [http://gentoo-wiki.com/HOWTO_Monitor_your_hard_disk(s)_with_smartmontools this wiki] for more.<br />
<br />
===Step 4: Make smartd automatically monitor your drives===<br />
smartd can be configured at start-up using the configuration file<br />
/etc/smartd.conf. If no configuration exists smartd monitors for <b>all</b> possible SMART errors (corresponding to the "-a" Directive in the configuration file).<br />
<br />
If the first non-comment entry in the configuration file is the text<br />
string DEVICESCAN in capital letters, then smartd will ignore any remaining <br />
lines in the configuration file, and will scan for devices. For an ATA device, if no Directives appear, then the device will be monitored as if the "-a" Directive (monitor all SMART properties) had been given.<br />
<br />
To make configuration for invidual devices you have to comment the line with DEVICESCAN and add a configuration line for every device. Here is an example (more are given inside /etc/smart.conf):<br />
<pre><br />
#DEVICESCAN<br />
<br />
/dev/hda -a -m root@localhost<br />
</pre><br />
This will monitor all atributes and send a warning email to root@localhost if a failure or a new error occurs. <br />
<br />
NOTE: To be able to send internal mail, you need a MTA like sendmail or [http://wiki.archlinux.org/index.php/PostFix_HostOnly_Howto postfix]<br />
<br />
Now start the deamon<br />
<pre><br />
/etc/rc.d/smartd start<br />
</pre><br />
If everything is working as it should, you can add smartd to your DAEMONS array in /etc/rc.conf<br />
<br />
=Resources=<br />
http://smartmontools.sourceforge.net/<br />
<br />
http://gentoo-wiki.com/HOWTO_Monitor_your_hard_disk(s)_with_smartmontools<br />
<br />
man smartctl<br />
<br />
man smartd</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=S.M.A.R.T.&diff=31045S.M.A.R.T.2007-10-18T07:05:55Z<p>Tkjacobsen: </p>
<hr />
<div>[[Category:HOWTOs (English)]]<br />
=SMART HOWTO=<br />
This page will describe how to setup SMART to monitor your harddisks.<br />
<br />
===Step 1: Install smartmontools===<br />
<pre><br />
pacman -Sy smartmontools<br />
</pre><br />
<br />
===Step 2: Check if your disk(s) support SMART===<br />
IDE-disks:<br />
<pre><br />
smartctl -i /dev/hda<br />
</pre><br />
SATA-disks:<br />
<pre><br />
smartctl -i -d ata /dev/sda<br />
</pre><br />
Look for:<br> <br />
"SMART support is: Available - device has SMART capability."<br><br />
"SMART support is: Enabled"<br><br />
If SMART is NOT enabled you have to do this.<br />
IDE-disks:<br />
<pre><br />
smartctl -s on /dev/hda<br />
</pre><br />
SATA-discs:<br />
<pre><br />
smartctl -s on -d ata /dev/sda<br />
</pre><br />
<br />
===Step 3: Check your disk(s)===<br />
Check the SMART health status of a device<br />
<pre><br />
smartctl -H /dev/sda<br />
</pre><br />
I all goes well, it will return PASSED. <br />
If the device reports <b>failing health status</b>, this means either that<br />
the device has already failed, or that it is predicting its own<br />
failure within the next 24 hours. If this happens, use the "-a"<br />
option to get more information, and <b>get your data off the disk and<br />
someplace safe as soon as you can</b>.<br />
<br />
Check the SMART Error Log<br />
<pre><br />
smartctl -l error /dev/sda<br />
</pre><br />
If we read No Errors Logged it's ok. If there are a few errors (and they are not so recent) you don't have to worry too much. If there are a lot of errors it's better if you backup your data as soon as you can.<br />
<br />
NOTE: This is not all tests but only two of them. See the manual or [http://gentoo-wiki.com/HOWTO_Monitor_your_hard_disk(s)_with_smartmontools this wiki] for more.<br />
<br />
===Step 4: Make smartd automatically monitor your drives===<br />
smartd can be configured at start-up using the configuration file<br />
/etc/smartd.conf. If no configuration exists smartd monitors for <b>all</b> possible SMART errors (corresponding to the "-a" Directive in the configuration file).<br />
<br />
If the first non-comment entry in the configuration file is the text<br />
string DEVICESCAN in capital letters, then smartd will ignore any remaining <br />
lines in the configuration file, and will scan for devices. For an ATA device, if no Directives appear, then the device will be monitored as if the "-a" Directive (monitor all SMART properties) had been given.<br />
<br />
To make configuration for invidual devices you have to comment the line with DEVICESCAN and add a configuration line for every device. Here is an example (more are given inside /etc/smart.conf):<br />
<pre><br />
#DEVICESCAN<br />
<br />
/dev/hda -a -m root@localhost<br />
</pre><br />
This will monitor all atributes and send a warning email to root@localhost if a failure or a new error occurs. <br />
<br />
NOTE: To be able to send internal mail, you need a MTA like sendmail or [http://wiki.archlinux.org/index.php/PostFix_HostOnly_Howto postfix]<br />
<br />
Now start the deamon<br />
<pre><br />
/etc/rc.d/smartd start<br />
</pre><br />
If everything is working as it should, you can add smartd to your DAEMONS array in /etc/rc.conf<br />
<br />
=Resources=<br />
http://smartmontools.sourceforge.net/<br />
<br />
http://gentoo-wiki.com/HOWTO_Monitor_your_hard_disk(s)_with_smartmontools</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=S.M.A.R.T.&diff=31044S.M.A.R.T.2007-10-18T06:19:55Z<p>Tkjacobsen: </p>
<hr />
<div>[[Category:HOWTOs (English)]]<br />
=SMART HOWTO=<br />
This page will describe how to setup S.M.A.R.T. to monitor your harddisks.<br />
<br />
===Step 1: Install smartmontools===<br />
<pre><br />
pacman -Sy smartmontools<br />
</pre><br />
<br />
===Step 2: Check if your disk(s) support SMART===<br />
IDE-disks:<br />
<pre><br />
smartctl -i /dev/hda<br />
</pre><br />
SATA-disks:<br />
<pre><br />
smartctl -i -d ata /dev/sda<br />
</pre><br />
Look for: "SMART support is: Available - device has SMART capability."<br />
and: "SMART support is: Enabled"<br />
If smart is NOT enabled you have to do this.<br />
IDE-disks:<br />
<pre><br />
smartctl -s on /dev/hda<br />
</pre><br />
SATA-discs:<br />
<pre><br />
smartctl -s on -d ata /dev/sda<br />
</pre><br />
<br />
<br />
TO BE CONTINUED</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=S.M.A.R.T.&diff=31009S.M.A.R.T.2007-10-17T20:43:46Z<p>Tkjacobsen: </p>
<hr />
<div>[[Category:HOWTOs (English)]]<br />
=SMART HOWTO=<br />
This page will describe how to setup S.M.A.R.T. to monitor your harddisks.<br />
<br />
===Step 1: Install smartmontools===<br />
<pre><br />
pacman -Sy smartmontools<br />
</pre><br />
<br />
===Step 2: Check if your disk(s) support SMART===<br />
IDE-disks:<br />
<pre><br />
smartctl -i /dev/hda<br />
</pre><br />
SATA-disks:<br />
<pre><br />
smartctl -i -d ata /dev/sda<br />
</pre><br />
Look for: "SMART support is: Available - device has SMART capability."<br />
<br />
TO BE CONTINUED</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=S.M.A.R.T.&diff=30998S.M.A.R.T.2007-10-17T15:47:21Z<p>Tkjacobsen: New page: Category:HOWTOs (English) =S.M.A.R.T. HOWTO= This page will describe how to setup S.M.A.R.T. to monitor your harddisks. ===Step 1: Install smartmontools=== <pre> pacman -Sy smartmonto...</p>
<hr />
<div>[[Category:HOWTOs (English)]]<br />
=S.M.A.R.T. HOWTO=<br />
This page will describe how to setup S.M.A.R.T. to monitor your harddisks.<br />
<br />
===Step 1: Install smartmontools===<br />
<pre><br />
pacman -Sy smartmontools<br />
</pre><br />
<br />
===Step 2: Check if your disk(s) support S.M.A.R.T===<br />
IDE-disks:<br />
<pre><br />
smartctl -i /dev/hda<br />
</pre><br />
SATA-disks:<br />
<pre><br />
smartctl -i -d ata /dev/sda<br />
</pre><br />
Look for: "SMART support is: Available - device has SMART capability."<br />
<br />
TO BE CONTINUED</div>Tkjacobsenhttps://wiki.archlinux.org/index.php?title=Hotkeys&diff=28406Hotkeys2007-09-03T07:49:53Z<p>Tkjacobsen: /* Printing characters in X */</p>
<hr />
<div>[[Category:Input devices (English)]]<br />
<br />
Many keyboards (mainly on laptops) include some "special keys", which are supposed to execute an app or to print special characters (not included in the standard national keymaps). The great variety of layouts of these keyboards determines some initial problems when you install linux in your system, since the keys do not work out of the box; however, once again, linux gives you the freedom to configure these keys to do exactly what you want. Only a minority of these keys are not seen at all by the linux kernel and thus cannot be used.<br />
<br />
There are many options to deal with special keys in linux (we are going to call them 'hotkeys' in what follows). The solutions discussed in this howto allow you to use them independently from the window manager or desktop environment you chose; moreover you will be able to use them in three possible ways (the second and the third way can not coexist for the same key):<br />
#to print a character in console;<br />
#to print a character in X;<br />
#to execute an app in X.<br />
Actually, you can do also the fourth thing, i.e. to execute an app in console, but this is made with a silly work-around and will be briefly described when discussing the first use in the list above (see [[#Printing characters in the console|below]]).<br />
<br />
Other approaches use comprehensive applications aiming to solve these problems (see e.g. the wiki howtos for [[Extra Keyboard Keys|keytouch]] and for [[Lineak]]), but these solutions are generally built on a wide database of known models of keyboards: this database seems to be condemned to be incomplete, since the variety of keyboard models does never stop to grow. The approach here considered allows the user to work with the internals of the system, tailoring the configuration to his own system as it is. Moreover, the other solutions assume that you want to use the hotkeys only when you are in X, while it is possible to take profit of them also if you are a console lover.<br />
<br />
All the keys we can hope to use in linux has a scancode. This scancode is generally associated with a keycode. This keycode is generally associated with a character to print in the console keymap. This keycode is also translated by X in another code, which the X keymaps generally bind to a certain character or to a certain command to run. Well, when an hotkey does not work for us, one or more of these things that generally happen do not happen. <br />
First of all, we have to discover what is the problem. <br />
This diagnosis will be explained in the [[#The diagnosis|first section]], but we sum up the possible scenarios, so that after the diagnosis we know where to look for a suitable medicine. We have to verify if the key has a scancode. If it has not a scancode, there is no hope that it works, so we have to give up. If it has a scancode but no keycode, we have to associate the scancode with a keycode: this will be explained in the [[#Associate scancodes with keycodes|second section]]. If it has already a keycode or if you gave it a keycode thanks to the second section, then we have to bind it to one or more of the three possible uses listed above: the [[#Printing characters in the console|third section]] explains how to make the key print a character in console; the [[#Printing characters in X|fourth section]] explains how to make the key print a character in X using xmodmap; the [[#Running applications in X|fifth section]] explains how to make the key run an application when in X, using xbindkeys.<br />
== The diagnosis ==<br />
The most global way to diagnose the situation is to go in console and use the 'showkey' utility. Please note that this utility will not work when in X. First of all we run <br />
$ showkey <br />
without options: 'showkey' waits for ten seconds that we press a key (after ten seconds it quits automatically) and displays the keycode of the key we pressed. Two scenarios are possible:<br />
#nothing is displayed: in this case the key has not a keycode and you have to read further this section;<br />
#some mysterious hexadecimal numbers are displayed; in this case the kernel already assigns a keycode to the key; we can pass over to sections [[#Printing characters in the console|3]], [[#Printing characters in X|4]] or [[#Running applications in X|5]], according to what we want to do with that key.<br />
In the first scenario, we have to investigate if the key has at least a scancode. The 'showkey' utility can help us again. Just use the '-s' option:<br />
$ showkey -s<br />
When we press our hotkey, two scenarios are possible:<br />
#nothing is displayed: the key is not seen in any way by our os, we whould give up;<br />
#a decimal code is displayed; the hotkey has a scancode; the [#Associate scancodes to keycodes|next section] will help you to associate this scancode with a keycode.<br />
== Associate scancodes with keycodes ==<br />
In order to accomplish this task, we need to resort to the utility 'setkeycodes', which, as you can see in its man page, associates scancodes to keycodes. Obviously enough, it takes two arguments: the first argument is the scancode, the second argument is the keycode. However, it is not always easy to determine these arguments. In order to determine the scancode, the output of the 'showkey -s' we used in the section above is not always illuminating, since sometimes the hotkeys - and the normal keys too - generate a double scancode. The simplest way to determine the exact scancode is to look at the system log: in fact, any time we press a key which has a scancode but no keycode, the kernel suggests us to use just 'setkeycodes' to assign a keycode to it. In the message the kernel gives us also the scancode we have to use actually. We will find it in the system log. However, also this code is not always usable as it is: when it is composed of four characters and starts with an 'e', then we can use it as it is as the first argument for 'setkeycodes'. On the contrary, when the kernel gives us only two digits, we have to prepend '0x' to it. As an example, suppose that the kernel tells us that the scancode is 71; then the first argument for 'setkeycodes' will be 0x71.<br />
<br />
The second argument is partially arbitrary. Partially! In fact:<br />
#the keycode has to be in the range 1-127;<br />
#it should not conflict with the keycodes already mapped to a character in your keymap.<br />
In order to respect the second condition, you have to look at your keymap. In configuring your system through /etc/rc.conf, you have chosen your keymap, or decided to stay with the default one: in fact rc.conf includes a 'KEYMAP' setting. The keymaps are stored in your system in one of the subfolders into /usr/share/kbd/keymaps/i386/. E.g., mine is the Italian keymap and its path is /usr/share/kbd/keymaps/i386/qwerty/it.map.gz. It is a text file compressed with gzip2. Let us gunzip it.<br />
# gunzip /usr/share/kbd/keymaps/i386/qwerty/it.map.gz<br />
Now we can read it (sometimes less is able to read also gzipped files: in this case the above passage is dispensable):<br />
# less /usr/share/kbd/keymaps/i386/qwerty/it.map<br />
We have to choose a keycode not conflicting with those already associated with characters. Most of the lines in the keymap are of the following format:<br />
keycode <keycode> = <keysym><br />
These lines are ordered according to the numeric value of the keycode, thus it is easy to find the highest keycode used by the keymap. Thus, the second argument for 'setkeycodes" has to in the range between the successor of this highest keycode and 127. <br />
<br />
Let us say that 112 is in this range (this is actually true with the italian keymap): now we can actually use 'setkeycodes':<br />
# setkeycodes 0x71 112<br />
If we run 'showkey' again, we can see that our hotkey has now the keycode 112. However, this is true only for the current session. To make this permanent, we need to execute 'setkeycodes' each time we boot our system. This can be done inserting the following line in /etc/rc.local:<br />
setkeycodes 0x71 112 &<br />
== Printing characters in the console ==<br />
When we are in console, we can use our hotkeys to print a certain character. Moreover we can also print a sequence of characters and some escape sequences. Thus, if we print the sequence of characters constituting a command and afterwards an escape character for a new line, that command will be executed!<br />
<br />
In order to do this, we could modify our console keymap. However, I suggest not to do this, since that is a delicate file and since it will be rewritten anytime we update the package it belongs to. It is better to integrate the existing keymap with a personal keymap. The utility 'loadkeys' can do this. <br />
<br />
First of all, we need to write down this file. You can put it as you prefer, but I prefer to mimic partially the hierarchy of the default keymaps into /usr/local. So:<br />
# mkdir -p /usr/local/share/kbd/keymaps<br />
# vim /usr/local/share/kbd/keymaps/personal.map<br />
As a side note, it is worth noting that such a personal keymap is useful also to redefine the behavior of keys already treated by the default keymap: in fact, when we load it with 'loadkeys' the directives in the default keymap will be replaced when they conflict with the new directives and conserved otherwise. <br />
<br />
Anyway, we need two kinds of directives in our personal keymaps. First of all, the keycode directives, with the format we have seen above in the default keymaps. These directives associate a keycode with a keysym. Keysyms represent keyboard actions. The actions available include outputting character codes or character sequences, switching consoles or keymaps, booting the machine etc. (The complete list can be obtained with <br />
$ dumpkeys -l<br />
Anyway, most of them are intuitive. If we want our key to output an 'e', the directive will be:<br />
keycode 112 = e<br />
If we want our hotkey to output the symbol of the euro currency, the directive will be:<br />
keycode 112 = euro<br />
Some keysym are not immediately connected to a keyboard actions. In particular the keysyms constituted by a capital F and two digits constituting a number greater than 30 are always free. This is useful for us if we want our hotkey to output a sequence of characters and other actions. In fact we can first of all bind our character to such a keysym:<br />
keycode 112 = F70<br />
Then we use another kind of directive, which binds the keysym to an action. E.g., if we want our hotkey to output a literal "Hello":<br />
string F70 = "Hello"<br />
This can seem not very useful. But we can use it to print and execute commands. In order to execute the printed command, I need to use an escape sequence corresponding to a new line. E.g., I can want an hotkey to hibernate my laptop also when I am a user (through sudo). In this case I write the following directive in my personal keymap.<br />
string F70 = "sudo /usr/sbin/hibernate\n"<br />
In order to take profit of my personal keymap, I have to load it with 'loadkeys':<br />
$ loadkeys /usr/local/share/kbd/keymaps/personal.map<br />
Also in this case, this is valid only for the current session. In order to accomplish the same result each time I boot my machine, I have to insert another line in /etc/rc.local. This line should come after the occurrences of 'setkeycodes' discussed in section 2, since the personal keymap resorts to the keycodes assigned through 'setkeycodes':<br />
loadkeys -q /usr/local/share/kbd/keymaps/personal.map&<br />
The '-q' option simply avoids that a confirmation message is printed to stdin during the boot process.<br />
== Printing characters in X ==<br />
Fortunately, when a character has a keycode in the system it is also seen inside X. X gives it a keycode: however, it is very important to stress that the X keycode is DIFFERENT from the system keycode. If you had to pass through section 1 of this article to assign a system keycode to your hotkey, you MUST forget this keycode when dealing with X, because X assigns a different keycode to the key (but requires that the key has a system keycode whatsoever). <br />
<br />
The most traditional and proficient way to make a key output a character when you are in X is to use xmodmap. Xmodmap is roughly the X equivalent of 'loadkeys' (see section 3): it reads a file containing some directives. As 'loadkeys', it can be used to modify many aspects of the behaviour of your keyboard (such as modifiers, etc.), but I will not cover these aspects in this article. The only kind of directive I am interested in here associates an X keycode to a keysym. 'xmodmap' is included in the 'xorg-server-utils' package.<br />
# pacman -S xorg-server-utils<br />
In order to use it we need to discover the X keycode of our beloved hotkey: we resort to 'xev'. 'xev' is included in the 'xorg-utils' package.<br />
# pacman -S xorg-utils<br />
'xev' (run it from a terminal window) open a white window and outputs in the terminal some codes and infos when you press (or relase) a key or move your mouse. Its output is redundant and difficult. Anyway, you will see clearly into it when you press your hotkey:<br />
keycode: <theXkeycodeofyourhotkey><br />
Once you have discovered the X keycodes of your hotkeys, you are ready to write the file that 'xmodmap' will parse. You can put it where you like, but since the xserver is executed by a user, it is customary to make it an hidden file in the home directory of the user:<br />
$ vim ~/.Xmodmap<br />
In this file, you have to list the keycode directives, with the following syntax:<br />
keycode <Xkeycode> = <keysym><br />
The list of X keysyms can be read in /usr/include/X11/keysymdef.h. Anyway, most of them are intuitive. Let us say that 'xev' has said that the X keycode of my hotkey is 239. If I want it to output a literal 'e', I will write the following directive:<br />
keycode 239 = e<br />
If I want it to output the symbol of the American currency, I will write the following directive:<br />
keycode 239 = dollar<br />
Finally I have to source the file with xmodmap:<br />
$ xmodmap ~/.Xmodmap<br />
Obviously, this will work only for the current X session, but it is better to make this automatically anytime I start X. This should be done in different ways according to your system configuration. E.g., if you use the old plain 'startx', you have to put the following line in .xinitrc before the line when you launch your window manager:<br />
xmodmap ~/.Xmodmap &<br />
<br />
<b>NOTE:</b><br />
This can also be used to assign functions to multimedia keys. Special functions can be found in /usr/share/X11/XKeysymDB.<br />
<br />
My (tkjacobsen) ~/.Xmodmap:<br />
<pre><br />
keycode 160 = XF86AudioMute<br />
keycode 176 = XF86AudioRaiseVolume<br />
keycode 174 = XF86AudioLowerVolume<br />
</pre><br />
<br />
== Running applications in X ==<br />
There are several utilities which aim to help you to bind keys (or keys combinations) to certain apps. Basically, they follow two main philosophies: some of them includes a database of existing keyboards and, once you have defined the model of your keyboard, should associate to keys the 'right' action (i.e. corresponding to the icon on the key...); some others allow you to associate the action you like to whatever key or key combination, disregarding stuff like icons. I have a strong preference for this second philosophy and will propose to use one of the utilities of this second kind. [[Lineak]] is an example of the first approach.<br />
<br />
Another option is to use the configuration files of the window manager. This is a very good solution, although it often requires that the key is associated (through xmodmap) with a keysym which the window manager then associates to an app to run. However, it is different for each of the existing window managers and can not be covered in this article.<br />
<br />
I propose to use xbindkeys. xbindkeys can be used together with any window manager (but its shortcuts can conflict with the shortcuts defined by the window manager).<br />
# pacman -S xbindkeys<br />
xbindkeys is widely documented in its man page:<br />
$ man xbindkeys <br />
Xbindkeys includes an utility to detect the X keycodes of keys and key combinations without resorting to 'xev'. Its output is much more readable than 'xev' output.<br />
$ xbindkeys -mk<br />
In the configuration file you can associate commands both to X keycodes and to keysyms. Your hotkeys, if you haven't already configured them through 'xmodmap' (see Section 4 above) are actually identifiable only through an X keycode. The man page enlightens exhaustively the syntax of the configuration file (~/.xbinkdekysrc). <br />
<br />
Once configured, 'xbindkeys' should be run when an X syntax starts. Thus, provided that you use 'startx' to start your x session, you can add the following line to your .xinitrc:<br />
xbindkeys &<br />
<br />
In this way, xbindkeys will fork in the background and be ready to react when you press the hotkeys (or the normal keys, or key combinations) you defined in the config file.</div>Tkjacobsen