Hardware installation procedure

12/08/2008


Status




Last updated on 03/10/2017 22:22 by Matthieu Guenebaud
Install aptitude

Type:

sudo apt-get install aptitude
Configure ufw firewall

Install ufw firewall:

sudo aptitude install ufw gufw

Activate netbios support:

sudo vi /etc/default/ufw

By adding:

# The nf_contrack_netbios_ns has been added
IPT_MODULES="nf_conntrack_ftp nf_nat_ftp nf_conntrack_irc nf_nat_irc nf_conntrack_netbios_ns"

Then apply the following rules:

Generic rules:

sudo ufw default deny incoming
sudo ufw default allow outgoing

Domain:

sudo ufw allow domain

Internet:

sudo ufw allow ssh
sudo ufw allow ftp
sudo ufw allow www
sudo ufw allow https
sudo ufw allow http-alt

Emails:

sudo ufw allow imaps
sudo ufw allow ssmtp
sudo ufw allow xmpp-client

Remote desktop:

sudo ufw allow 5900

Samba:

sudo ufw allow 113
sudo ufw allow proto tcp from 192.168.0.0/24 to 192.168.0.0/24 port 135
sudo ufw allow proto tcp from 192.168.0.0/24 to 192.168.0.0/24 port 139
sudo ufw allow proto tcp from 192.168.0.0/24 to 192.168.0.0/24 port 445
sudo ufw allow proto udp from 192.168.0.0/24 to 192.168.0.0/24 port 137
sudo ufw allow proto udp from 192.168.0.0/24 to 192.168.0.0/24 port 138

Transmission:

sudo ufw allow 9099
sudo ufw allow 20500:20599/tcp
sudo ufw allow 20500:20599/udp

Printer sharing:

sudo ufw allow 631

NTP:

sudo ufw allow ntp

Squeezeserver:

sudo ufw allow 9000
sudo ufw allow 9090
sudo ufw allow 3483

Before applying the new rules, the logging can be activated with:

sudo ufw logging on

Then reload the configuration with:

sudo ufw enable

The firewall status is visible with:

sudo ufw status

To stop the firewall, the command is:

sudo ufw disable

All the existing rules can be removed with:

sudo ufw reset

And finally, to display the log, type:

sudo tail -f /var/log/ufw.log
Activate remove desktop

In ubuntu settings, activate sharing desktop remotely.

Mount network drives

First create the destination folders:

sudo mkdir /nas
sudo mkdir /nas/Documents
sudo mkdir /nas/Livres
sudo mkdir /nas/Musique
sudo mkdir /nas/Photos
sudo mkdir /nas/Cabinet
sudo mkdir /nas/Sauvegardes
sudo mkdir /nas/Video
sudo mkdir /nas/Tmp
sudo mkdir /nas/Download
sudo mkdir /nas/Freebox

With the proper rights:

sudo chown -R LOGIN /nas

Then edit the file:

sudo vi /etc/fstab

And add the following lines (replace LOGIN and PASSWORD with their values):

# Add Buffalo NAS HDD mount
//192.168.0.100/Documents /nas/Documents cifs username=LOGIN,password=PASSWORD,rw,iocharset=utf8,file_mode=0777,dir_mode=0777,_netdev 0 0
//192.168.0.100/Livres /nas/Livres cifs username=LOGIN,password=PASSWORD,rw,iocharset=utf8,file_mode=0777,dir_mode=0777,_netdev 0 0
//192.168.0.100/Musique /nas/Musique cifs username=LOGIN,password=PASSWORD,rw,iocharset=utf8,file_mode=0777,dir_mode=0777,_netdev 0 0
//192.168.0.100/Photos /nas/Photos cifs username=LOGIN,password=PASSWORD,rw,iocharset=utf8,file_mode=0777,dir_mode=0777,_netdev 0 0
//192.168.0.100/Cabinet /nas/Cabinet cifs username=LOGIN,password=PASSWORD,rw,iocharset=utf8,file_mode=0777,dir_mode=0777,_netdev 0 0
//192.168.0.100/Sauvegardes /nas/Sauvegardes cifs username=LOGIN,password=PASSWORD,rw,iocharset=utf8,file_mode=0777,dir_mode=0777,_netdev 0 0
//192.168.0.100/Video /nas/Video cifs username=LOGIN,password=PASSWORD,rw,iocharset=utf8,file_mode=0777,dir_mode=0777,_netdev 0 0
//192.168.0.100/Tmp /nas/Tmp cifs username=LOGIN,password=PASSWORD,rw,iocharset=utf8,file_mode=0777,dir_mode=0777,_netdev 0 0
//192.168.0.100/Download /nas/Download cifs username=LOGIN,password=PASSWORD,rw,iocharset=utf8,file_mode=0777,dir_mode=0777,_netdev 0 0
# Add freebox NAS
//192.168.0.254/Disque\040dur /nas/Freebox cifs username=freebox,password=PASSWORD,directio,uid=1000,iocharset=utf8,codepage=cp850,file_mode=0777,dir_mode=0777,_netdev 0 0

To apply the new configuration without reboot:

sudo mount -a

To disable the configuration:

sudo umount -a
Improve unity

Activate the display of hidden and backup files in nautilus settings, then type:

sudo aptitude install nautilus-image-converter nautilus-open-terminal

Uncompress the following file content:

in the user shortcuts folder:

/home/guenmat/.local/share/applications
Google Chrome

Download the latest google chrome at:

Then type:

sudo dpkg -i google-chrome-stable_current_*.deb
Install softwares

• MPlayer

• Filezilla

• Calibre

• Comix

• Gimp

Startup applications

By default, ubuntu hides all startup applications in tool "Startup applications". To display them all, type:

cd /etc/xdg/autostart/
sudo sed --in-place 's/NoDisplay=true/NoDisplay=false/g' *.desktop

In order to hide them again, type:

cd /etc/xdg/autostart/
sudo sed --in-place 's/NoDisplay=false/NoDisplay=true/g' *.desktop
Configure transmission

Do not forget to add blocking rules from the site:

http://www.iblocklist.com/lists.php

More precisely for France, apply:

http://list.iblocklist.com/?list=fr&fileformat=p2p&archiveformat=gz

Start transmission on startup

transmission-gtk -m
Add drivers for printer Samsung SCX-3405FW

Edit the file:

sudo vi /etc/apt/sources.list

And add the following lines:

#add the Samsung Unified Driver Repo
deb http://www.bchemnet.com/suldr/ debian extra

Then type:

wget http://www.bchemnet.com/suldr/suldr.gpg
sudo apt-key add suldr.gpg
sudo aptitude update
sudo aptitude install samsungmfp-data samsungmfp-driver samsungmfp-network samsungmfp-scanner samsungmfp-configurator-data samsungmfp-configurator-qt4 libsane-extras

Declare the printer:

sudo vi /etc/sane.d/xerox_mfp.conf

By adding

# Samsung SCX-3400
usb 0x04e8 0x344f

Do the same in:

sudo vi /lib/udev/rules.d/40-libsane.rules

By adding

# Samsung SCX-3400
ATTRS{idVendor}=="04e8", ATTRS{idProduct}=="344f", ENV{libsane_matched}="yes"

Then, plug the printer and follow the instructions.

The scanner only works on USB.

Install squeezecenter

Download the latest version at:

Then type:

sudo dpkg -i logitechmediaserver_*_all.deb

The sofware will be available at:

Install Conky

Type:

sudo aptitude install conky

Then download scripts at:

And type:

tar xzvf conkytheme.tar.gz
mv .conkytheme /home/guenmat

To try manually the configuration, type:

conky -c /home/guenmat/.conkytheme/conkyrc-eeebox-big-2

In order to start conky automatically on startup, create a new script with:

vi ~/conkystartup.sh

And paste the following content:

#!/bin/bash
sleep 15&&
conky -c /home/guenmat/.conkytheme/conkyrc-eeebox-big-2

Change the script execution rights:

sudo chmod +x ~/conkystartup.sh

Then use the ubuntu "Startupt applications" tool to create a new entry calling the previous script.

Install teamviewer

Download the latest 32bits version at:

Then type:

sudo aptitude install gdebi
sudo gdebi teamviewer_linux.deb
sudo rm -f teamviewer_linux.deb

Validate and proceed with the installation.

Backup data

Type:

rsync -ar --delete --progress --size-only /nas/Cabinet/Papiers/* /media/DDExterne/Cabinet
rsync -ar --delete --progress --size-only /nas/Documents/* /media/DDExterne/Documents
rsync -ar --delete --progress --size-only /nas/Photos/* /media/DDExterne/Photos
Disable crash reports

Type:

sudo vi /etc/default/whoopsie

And replace the value for the line to false

report_crashes=false

Then stop the service

sudo stop whoopsie