Révision: 3.00 FR (Dernière mise à jour le 11 juillet 2005) - Changelog
URL: http://www.ubuntuguide.org
Auteur: Chua Wen Kiat (Kuala Lumpur, Malaysia)
Traduit de l'anglais par: Sam Grandjean , Joseph Sartre
Merci à: Globule et l'équipe de Ubuntu-fr pour tout leur travail
http://fr.ubuntuguide.org/
Copyright (C) 2004-2005 http://www.ubuntuguide.org
Ce programme est un logiciel libre; vous avez le droit de le diffuser et/ou le modifier, selon les termes de la Licence Publique Générale GNU (GPL), telle que publiée par la Free Software Foundation, que ce soit la version 2 de la licence ou (à votre gré) toute version postérieure.
Ce programme est diffusé avec l'espoir qu'il sera utile, mais SANS AUCUNE GARANTIE; même sans la garantie implicite d'usage ou d'adaptation à un but précis. Référez-vous à la Licence Publique Générale GNU (GPL) pour de plus amples détails.
Q: Où trouver des captures d'écran de Ubuntu?
Q: Où trouver une liste des programmes/librairies livrés avec Ubuntu?
Q: Où commander des CDs d'Ubuntu entièrement GRATUITEMENT?
Q: Où trouver de l'aide pour Ubuntu?
Q: Où télécharger le Guide Ubuntu en entier?
wget -c http://ubuntuguide.org/ubuntu5.04.tar.gz tar zxvf ubuntu5.04.tar.gz
Q: Où télécharger le CD additionnel non-officiel pour Ubuntu?
Q: Comment ajouter des dépôts supplémentaires?
sudo cp /etc/apt/sources.list /etc/apt/sources.list_backup sudo gedit /etc/apt/sources.list
... ## Uncomment the following two lines to fetch updated software from the network # deb http://us.archive.ubuntu.com/ubuntu hoary main restricted # deb-src http://us.archive.ubuntu.com/ubuntu hoary main restricted ## Uncomment the following two lines to fetch major bug fix updates produced ## after the final release of the distribution. # deb http://us.archive.ubuntu.com/ubuntu hoary-updates main restricted # deb-src http://us.archive.ubuntu.com/ubuntu hoary-updates main restricted ## Uncomment the following two lines to add software from the 'universe' ## repository. ## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu ## team, and may not be under a free licence. Please satisfy yourself as to ## your rights to use the software. Also, please note that software in ## universe WILL NOT receive any review or updates from the Ubuntu security ## team. # deb http://us.archive.ubuntu.com/ubuntu hoary universe # deb-src http://us.archive.ubuntu.com/ubuntu hoary universe # deb http://security.ubuntu.com/ubuntu hoary-security main restricted # deb-src http://security.ubuntu.com/ubuntu hoary-security main restricted # deb http://security.ubuntu.com/ubuntu hoary-security universe # deb-src http://security.ubuntu.com/ubuntu hoary-security universe
## Uncomment the following two lines to fetch updated software from the network deb http://us.archive.ubuntu.com/ubuntu hoary main restricted deb-src http://us.archive.ubuntu.com/ubuntu hoary main restricted ## Uncomment the following two lines to fetch major bug fix updates produced ## after the final release of the distribution. deb http://us.archive.ubuntu.com/ubuntu hoary-updates main restricted deb-src http://us.archive.ubuntu.com/ubuntu hoary-updates main restricted ## Uncomment the following two lines to add software from the 'universe' ## repository. ## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu ## team, and may not be under a free licence. Please satisfy yourself as to ## your rights to use the software. Also, please note that software in ## universe WILL NOT receive any review or updates from the Ubuntu security ## team. deb http://us.archive.ubuntu.com/ubuntu hoary universe deb-src http://us.archive.ubuntu.com/ubuntu hoary universe deb http://security.ubuntu.com/ubuntu hoary-security main restricted deb-src http://security.ubuntu.com/ubuntu hoary-security main restricted deb http://security.ubuntu.com/ubuntu hoary-security universe deb-src http://security.ubuntu.com/ubuntu hoary-security universe deb http://archive.ubuntu.com/ubuntu hoary multiverse deb-src http://archive.ubuntu.com/ubuntu hoary multiverse ## Backports deb http://ubuntu-backports.mirrormax.net/ hoary-backports main universe multiverse restricted deb http://ubuntu-backports.mirrormax.net/ hoary-extras main universe multiverse restricted
gpg --keyserver wwwkeys.eu.pgp.net --recv-keys 1F41B907 gpg --armor --export 1F41B907 | sudo apt-key add - sudo apt-get update
Q: Comment sauvegarder/restaurer les paquets déjà téléchargés en cache?
mkdir -p $HOME/backup/var/lib/ sudo cp -R /var/lib/apt/ $HOME/backup/var/lib/ mkdir -p $HOME/backup/var/cache/ sudo cp -R /var/cache/apt/ $HOME/backup/var/cache/ mkdir -p $HOME/backup/etc/apt sudo cp -R /etc/apt/ $HOME/backup/etc/ sudo chown -R $USER $HOME/backup/
sudo cp -fR $HOME/backup/var/* /var/ sudo cp -fR $HOME/backup/etc/apt/* /etc/apt/
Q: Comment mettre à jour Ubuntu manuellement?
sudo apt-get update sudo apt-get upgrade
Q: Comment installer un éditeur de menu pour GNOME (Smeg)?
wget -c http://frankandjacq.com/ubuntuguide/smeg_0.5-0ubuntu1_all.deb sudo dpkg -i smeg_0.5-0ubuntu1_all.deb
Q: Comment installer un presse-papier pour GNOME (Clipboard Daemon)?
wget -c http://frankandjacq.com/ubuntuguide/gnome-clipboard-daemon-1.0.bin.tar.bz2 sudo tar jxvf gnome-clipboard-daemon-1.0.bin.tar.bz2 -C /usr/bin/ sudo chown root:root /usr/bin/gnome-clipboard-daemon sudo chmod 755 /usr/bin/gnome-clipboard-daemon sudo gnome-clipboard-daemon &
Onglet Programmes au démarrage -> Ajouter Commande de démarrage: gnome-clipboard-daemon Ordre: 80
Q: Comment installer J2SE Runtime Environment (JRE) avec plug-in pour Mozilla Firefox?
sudo apt-get install sun-j2re1.5 java -version
Q: Comment installer le plug-in Flash (Macromedia Flash) pour Mozilla Firefox?
sudo apt-get install flashplayer-mozilla
Q: Comment installer PDF Reader (Adobe Reader) avec plug-in pour Mozilla Firefox?
sudo apt-get install acroread sudo apt-get install mozilla-acroread sudo apt-get install acroread-plugins
Q: Comment installer un gestionnaire de téléchargements (Downloader for X)?
sudo apt-get install d4x
Q: Comment installer un client FTP (gFTP)?
sudo apt-get install gftp
Q: Comment installer un client P2P BitTorrent (Azureus)?
sudo apt-get install azureus
Q: Comment installer un client P2P eMule (aMule)?
sudo apt-get install amule
Q: Comment installer un client P2P Gnutella (LimeWire)?
wget -c http://frankandjacq.com/ubuntuguide/LimeWireSoftOther.zip sudo unzip -u LimeWireSoftOther.zip -d /opt/ sudo chown -R root:root /opt/LimeWire/ sudo gedit /usr/bin/runLime.sh
cd /opt/LimeWire/ ./runLime.sh
sudo chmod +x /usr/bin/runLime.sh sudo gedit /usr/share/applications/LimeWire.desktop
[Desktop Entry] Name=LimeWire Comment=LimeWire Exec=runLime.sh Icon=/opt/LimeWire/LimeWire.ico Terminal=false Type=Application Categories=Application;Network;
Q: Comment installer un logiciel de téléphonie voIP (Skype)?
sudo apt-get install libqt3c102-mt wget -c http://frankandjacq.com/ubuntuguide/skype_1.1.0.20-1_i386.deb sudo dpkg -i skype_1.1.0.20-1_i386.deb
Q: Comment installer WinPopup (LinPopUp)?
sudo apt-get install linpopup sudo gedit /usr/share/applications/linpopup.desktop
[Desktop Entry] Name=LinPopUp Comment=LinPopUp Exec=linpopup Icon=/usr/share/pixmaps/linpopup.xpm Terminal=false Type=Application Categories=Application;Utility;
Q: Comment installer les codecs multimédia?
sudo apt-get install gstreamer0.8-plugins sudo apt-get install gstreamer0.8-lame sudo apt-get install gstreamer0.8-ffmpeg sudo apt-get install w32codecs sudo apt-get install libdivx4linux sudo apt-get install lame sudo apt-get install sox sudo apt-get install ffmpeg sudo apt-get install mjpegtools sudo apt-get install vorbis-tools gst-register-0.8
Q: Comment installer la lecture de DVD?
sudo apt-get install libdvdcss2
Q: Comment installer un lecteur multimédia (xine-ui)?
sudo apt-get install xine-ui
Q: Comment installer un lecteur multimédia (MPlayer) avec plug-in pour Mozilla Firefox?
sudo apt-get install mplayer-386 sudo apt-get install mplayer-fonts sudo apt-get install mozilla-mplayer sudo cp /etc/mplayer/mplayer.conf /etc/mplayer/mplayer.conf_backup sudo gedit /etc/mplayer/mplayer.conf
... vo=x11, # To specify default video driver (see -vo help for ...
vo=xv, # To specify default video driver (see -vo help for
Q: Comment installer un lecteur multimédia (XMMS)?
sudo apt-get install xmms wget -c http://frankandjacq.com/ubuntuguide/xmms-wma_1.0.4-2_i386.deb sudo dpkg -i xmms-wma_1.0.4-2_i386.deb
Q: Comment installer un lecteur multimédia (RealPlayer)?
sudo apt-get install realplayer
Q: Comment installer Stream Directory Browser (streamtuner)?
sudo apt-get install streamtuner
Q: Comment installer un éditeur vidéo (Kino)?
sudo apt-get install kino
Q: Comment installer un éditeur audio (Audacity)?
sudo apt-get install audacity
Q: Comment installer un extracteur de DVD (dvd::rip)?
sudo apt-get -t testing install transcode sudo apt-get install dvdrip sudo gedit /usr/share/applications/dvdrip.desktop
[Desktop Entry] Name=dvd::rip Comment=dvd::rip Exec=dvdrip Icon=/usr/share/perl5/Video/DVDRip/icon.xpm Terminal=false Type=Application Categories=Application;AudioVideo;
Q: Comment installer un extracteur de CD (Goobox)?
sudo apt-get install goobox sudo rm -f /usr/share/applications/goobox.desktop sudo gedit /usr/share/applications/goobox.desktop
[Desktop Entry] Name=CD Player & Ripper Comment=Lire et extraire des CDs Exec=goobox Icon=goobox.png Terminal=false Type=Application Categories=Application;AudioVideo;
Q: Comment installer un client e-mail (Mozilla Thunderbird)?
sudo apt-get install mozilla-thunderbird
Q: Comment installer un lecteur de news (Pan)?
sudo apt-get install pan
Q: Comment installer un lecteur de fils RSS/RDF/Atom (RSSOwl)?
wget -c http://frankandjacq.com/ubuntuguide/rssowl_linux_1_1_1_bin.tar.gz sudo tar zxvf rssowl_linux_1_1_1_bin.tar.gz -C /opt/ sudo chown -R root:root /opt/rssowl_linux_1_1_1_bin/ sudo gedit /usr/bin/runRSSOwl.sh
export MOZILLA_FIVE_HOME=/usr/lib/mozilla-firefox export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:${MOZILLA_FIVE_HOME}:${LD_LIBRARY_PATH} cd /opt/rssowl_linux_1_1_1_bin/ ./run.sh
sudo chmod +x /usr/bin/runRSSOwl.sh sudo gedit /usr/share/applications/RSSOwl.desktop
[Desktop Entry] Name=RSSOwl Comment=RSS / RDF / Atom Newsreader Exec=runRSSOwl.sh Icon=/opt/rssowl_linux_1_1_1_bin/rssowl.xpm Terminal=false Type=Application Categories=Application;Network;
Q: Comment installer un éditeur HTML (Nvu)?
sudo apt-get install nvu sudo rm -f /usr/share/applications/nvu.desktop sudo gedit /usr/share/applications/nvu.desktop
[Desktop Entry] Name=Nvu Comment=Nvu Exec=/opt/nvu-1.0PR/nvu Icon=/opt/nvu-1.0PR/icons/mozicon50.xpm Terminal=false Type=Application Categories=Application;Office;
Q: Comment installer un gestionnaire de projet (Planner)?
sudo apt-get install planner
Q: Comment installer un logiciel de PAO (Scribus)?
sudo apt-get install scribus
Q: Comment installer un éditeur de diagramme (Dia)?
sudo apt-get install dia-gnome
Q: Comment installer un logiciel de gravure CD/DVD (GnomeBaker)?
sudo apt-get install gnomebaker
Q: Comment installer un client pour les connections ADSL/PPPoE (RP-PPPoE)?
wget -c http://frankandjacq.com/ubuntuguide/rp-pppoe-3.5.tar.gz sudo tar zxvf rp-pppoe-3.5.tar.gz -C /opt/ sudo chown -R root:root /opt/rp-pppoe-3.5/ sudo gedit /usr/share/applications/RP-PPPoE.desktop
[Desktop Entry] Name=RP-PPPoE Comment=RP-PPPoE Exec=gksudo /opt/rp-pppoe-3.5/go-gui Icon= Terminal=false Type=Application Categories=Application;System;
Q: Comment installer un gestionnaire de démarrage (BUM)?
wget -c http://frankandjacq.com/ubuntuguide/bum_1.3.0-1_all.deb sudo dpkg -i bum_1.3.0-1_all.deb
Q: Comment installer un logiciel de partitionnement (GParted)?
sudo apt-get install gparted
Q: Comment installer un firewall (Firestarter)?
sudo apt-get install firestarter
Q: Comment installer un scanner de vulnerabilités (Nessus)?
sudo apt-get install nessus sudo apt-get install nessusd sudo nessus-adduser sudo ln -fs /etc/init.d/nessusd /etc/rc2.d/S20nessusd sudo /etc/init.d/nessusd start sudo gedit /usr/share/applications/Nessus.desktop
[Desktop Entry] Name=Nessus Comment=Nessus Exec=nessus Icon= Terminal=false Type=Application Categories=Application;System;
Q: Comment installer un logiciel de compression RAR (rar)?
sudo apt-get install rar sudo ln -fs /usr/bin/rar /usr/bin/unrar
Q: Comment installer des polices supplémentaires?
sudo apt-get install xfonts-intl-arabic sudo apt-get install xfonts-intl-asian sudo apt-get install xfonts-intl-chinese sudo apt-get install xfonts-intl-chinese-big sudo apt-get install xfonts-intl-european sudo apt-get install xfonts-intl-japanese sudo apt-get install xfonts-intl-japanese-big sudo apt-get install xfonts-intl-phonetic sudo apt-get install gsfonts-x11 sudo apt-get install msttcorefonts sudo fc-cache -f -
Q: Comment installer des Desktop Applets (gDesklets)?
sudo apt-get install gdesklets sudo apt-get install gdesklets-data
Q: Comment installer Chinese Input Method (SCIM)?
sudo apt-get install scim sudo apt-get install scim-chinese sudo apt-get install scim-config-socket sudo apt-get install scim-gtk2-immodule sudo apt-get install scim-tables-zh wget -c http://frankandjacq.com/ubuntuguide/fireflysung-1.3.0.tar.gz sudo tar zxvf fireflysung-1.3.0.tar.gz -C /usr/share/fonts/truetype/ sudo chown -R root:root /usr/share/fonts/truetype/fireflysung-1.3.0/ sudo fc-cache -f -v
Appuyer sur 'Ctrl + Espace'
Q: Comment installer un jeu (Frozen-Bubble)?
sudo apt-get install frozen-bubble
Q: Comment installer un compilateur (build-essential)?
sudo apt-get install build-essential
Q: Comment installer Windows 9X/ME/2000/XP (Win4Lin)?
Q: Comment installer des applications Windows (CrossOver Office)?
Q: Comment installer des jeux Windows (Cedega)?
Q: Comment installer le driver NVIDIA?
sudo apt-get install nvidia-glx sudo apt-get install nvidia-settings sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf_backup sudo nvidia-glx-config enable sudo gedit /usr/share/applications/NVIDIA-Settings.desktop
[Desktop Entry] Name=NVIDIA Settings Comment=NVIDIA Settings Exec=nvidia-settings Icon= Terminal=false Type=Application Categories=Application;System;
Q: Comment désactiver le logo NVIDIA au démarrage?
sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf_backup sudo gedit /etc/X11/xorg.conf
... Section "Device" Identifier "NVIDIA Corporation NV11 [GeForce2 MX/MX 400]" Driver "nvidia" BusID "PCI:1:0:0" ...
Option "NoLogo"
Q: Comment identifier le chipset d'un modem?
wget -c http://frankandjacq.com/ubuntuguide/scanModem.gz gunzip -c scanModem.gz > scanModem chmod +x scanModem sudo ./scanModem gedit Modem/ModemData.txt
Q: Comment installer un driver pour modem (SmartLink)?
uname -r (doit être 2.6.10-5-386) wget -c http://frankandjacq.com/ubuntuguide/sl-modem-modules-2.6.10-5-386_2.9.9a-1ubuntu2+2.6.10-34_i386.deb sudo dpkg -i sl-modem-modules-*.deb sudo apt-get install sl-modem-daemon
Q: Comment configurer un périphérique de type PamlOS?
sudo gedit /etc/udev/rules.d/10-custom.rules
BUS="usb", SYSFS{product}="Palm Handheld*", KERNEL="ttyUSB*", NAME{ignore_remove}="pilot", MODE="666"
Q: Comment lister la table de partition?
sudo fdisk -l
Q: Comment connaître l'espace disque utilisé?
df -T -h
Q: Comment lister les périphériques montés?
mount
Q: Comment lister les périphériques PCI?
lspci
Q: Comment lister les périphériques USB?
lsusb
Q: Comment accélérer la vitesse des lecteurs CD/DVD-ROM?
Par ex. Admettons que /dev/cdrom est le CD/DVD-ROM
sudo hdparm -d1 /dev/cdrom sudo cp /etc/hdparm.conf /etc/hdparm.conf_backup sudo gedit /etc/hdparm.conf
/dev/cdrom { dma = on }
Par ex. Admettons que /media/cdrom0/ est le point de montage du CD/DVD-ROM
sudo mount /media/cdrom0/ -o unhide
sudo umount /media/cdrom0/
Q: Comment forcer le démontage d'un CD/DVD-ROM?
Par ex. Admettons que /media/cdrom0/ est le point de montage du CD/DVD-ROM
sudo umount /media/cdrom0/ -l
Q: Comment rafraîchir les points de montage du fichier /etc/fstab sans redémarrer?
sudo mount -a
Q: Comment activer/désactiver une connexion réseau?
Onglet Connexions -> Sélectionner "Connexion Ethernet" -> Activer/Désactiver
Q: Comment configurer les connexions réseau?
Onglet Connexions -> Sélectionner "Connexion Ethernet" -> Propriétés Connection -> Ce périphérique est configuré (Coché) Paramètres de la connexion -> Configuration: Sélectionner "DHCP ou Adresse IP statique" Onglet DNS -> Serveurs DNS -> Ajouter/Supprimer
Q: Comment changer le nom de l'ordinateur?
Onglet général -> Paramètres de l'hôte -> Hôte: Indiquer le nom de l'ordinateur
Q: Comment changer la description de l'ordinateur?
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... server string = %h server (Samba, Ubuntu) ...
server string = nouvelle_description_de_l'ordinateur
sudo testparm sudo /etc/init.d/samba restart
Q: Comment changer le Domaine/Groupe de travail de l'ordinateur?
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... workgroup = MSHOME ...
workgroup = nouveau_domaine_ou_groupe_de_travail
sudo testparm sudo /etc/init.d/samba restart
Par ex. Admettons que la connection internet est correctement configurée Enregistrer un DNS dynamique gratuitement sur https://www.dyndns.org Rafraîchir automatiquement l'adresse IP dans la base de données DNS de DynDNS chaque heure * * * * * signifie minute heure date mois année
sudo apt-get install ipcheck sudo gedit /root/dyndns_update.sh
USERNAME=myusername PASSWORD=mypassword HOSTNAME=myhostname.dyndns.org cd /root/ if [ -f /root/ipcheck.dat ]; then ipcheck -r checkip.dyndns.org:8245 $USERNAME $PASSWORD $HOSTNAME else ipcheck --makedat -r checkip.dyndns.org:8245 $USERNAME $PASSWORD $HOSTNAME fi
sudo chmod 700 /root/dyndns_update.sh sudo sh /root/dyndns_update.sh export EDITOR=gedit && sudo crontab -e
00 * * * * sudo sh /root/dyndns_update.sh
Q: Comment partager un dossier facilement?
Clic droit sur le dossier -> Dossier partagé Répertoire partagé -> Partager avec: Sélectionner "SMB" Propriétés du partage -> Nom: Spécifier le nom du partage
Q: Comment parcourir le réseau interne?
Par ex. Admettons que les connections réseaux soient configurées correctement Si les ordinateurs ou les dossiers partagés n'apparaissent pas, essayer en accès direct Lire Comment accéder aux dossiers partagés du réseau sans les monter?
Q: Comment accéder aux dossiers partagés du réseau sans les monter?
Par ex. Admettons que les connexions réseaux soient configurées correctement Adresse IP de l'ordinateur distant: 192.168.0.1 Nom du dossier partagé: linux
smb://192.168.0.1/linux
Par ex. Admettons que les connexions réseaux soient configurées correctement Adresse IP de l'ordinateur distant: 192.168.0.1 Nom de l'utilisateur réseau: myusername Mot de passe de l'utilisateur réseau: mypassword Nom du dossier partagé: linux Point de montage local du dossier partagé: /media/sharename
sudo mkdir /media/sharename sudo mount //192.168.0.1/linux /media/sharename/ -o username=myusername,password=mypassword
sudo umount /media/sharename/
Par ex. Admettons que les connexions réseaux soient configurées correctement Adresse IP de l'ordinateur distant: 192.168.0.1 Nom de l'utilisateur réseau: myusername Mot de passe de l'utilisateur réseau: mypassword Nom du dossier partagé: linux Point de montage local du dossier partagé: /media/sharename
sudo mkdir /media/sharename sudo mount //192.168.0.1/linux /media/sharename/ -o username=myusername,password=mypassword,dmask=777,fmask=777
sudo umount /media/sharename/
Par ex. Admettons que les connexions réseaux soient configurées correctement Adresse IP de l'ordinateur distant: 192.168.0.1 Nom de l'utilisateur réseau: myusername Mot de passe de l'utilisateur réseau: mypassword Nom du dossier partagé: linux Point de montage local du dossier partagé: /media/sharename
sudo mkdir /media/sharename sudo gedit /root/.smbcredentials
username=myusername password=mypassword
sudo cp /etc/fstab /etc/fstab_backup sudo gedit /etc/fstab
//192.168.0.1/linux /media/sharename smbfs credentials=/root/.smbcredentials 0 0
Par ex. Admettons que les connexions réseaux soient configurées correctement Adresse IP de l'ordinateur distant: 192.168.0.1 Nom de l'utilisateur réseau: myusername Mot de passe de l'utilisateur réseau: mypassword Nom du dossier partagé: linux Point de montage local du dossier partagé: /media/sharename
sudo mkdir /media/sharename sudo gedit /root/.smbcredentials
username=myusername password=mypassword
sudo cp /etc/fstab /etc/fstab_backup sudo gedit /etc/fstab
//192.168.0.1/linux /media/sharename smbfs credentials=/root/.smbcredentials,dmask=777,fmask=777 0 0
Par ex. Admettons que /dev/hda1 soit le point de montage de la partition Windows (NTFS) Dossier pour le point de montage: /media/windows
sudo mkdir /media/windows sudo mount /dev/hda1 /media/windows/ -t ntfs -o umask=0222
sudo umount /media/windows/
Par ex. Admettons que /dev/hda1 soit le point de montage de la partition Windows (FAT) Dossier pour le point de montage: /media/windows
sudo mkdir /media/windows sudo mount /dev/hda1 /media/windows/ -t vfat -o umask=000
sudo umount /media/windows/
Par ex. Admettons que /dev/hda1 soit le point de montage de la partition Windows (NTFS) Dossier pour le point de montage: /media/windows
sudo mkdir /media/windows sudo cp /etc/fstab /etc/fstab_backup sudo gedit /etc/fstab
/dev/hda1 /media/windows ntfs umask=0222 0 0
Par ex. Admettons que /dev/hda1 soit le point de montage de la partition Windows (FAT) Dossier pour le point de montage: /media/windows
sudo mkdir /media/windows sudo cp /etc/fstab /etc/fstab_backup sudo gedit /etc/fstab
/dev/hda1 /media/windows vfat umask=000 0 0
Q: Comment activer/choisir/modifier le mot de passe root?
sudo passwd root
Q: Comment désactiver le compte utilisateur root?
sudo passwd -l root
Q: Comment autoriser l'utilisateur root à se connecter dans GNOME?
Onglet sécurité -> Options -> Autoriser root à se connecter en local avec GDM (Coché)
Q: Comment passer en utilisateur root dans un Terminal?
sudo -s -H Password: <votre mot de passe utilisateur>
Q: Comment ajouter/éditer/supprimer un utilisateur?
Onglet utilisateurs -> Ajouter un utilisateur.../Propriétés/Supprimer
Q: Comment ajouter/éditer/supprimer un groupe?
Onglet Groupes -> Ajouter Groupe.../Propriétés/Supprimer
Q: Comment se connecter automatiquement dans GNOME (non sécurisé)?
Onglet Général -> Connexion automatique -> Connecter automatiquement au premier démarrage (Coché) Identifiant de connexion automatique: Sélectionner l'utilisateur
Q: Comment ajouter des utilisateurs pouvant utiliser "sudo"?
export EDITOR=gedit && sudo visudo
system_username ALL=(ALL) ALL
Q: Comment utiliser "sudo" sans mot de passe (non sécurisé)?
export EDITOR=gedit && sudo visudo
... system_username ALL=(ALL) ALL ...
system_username ALL=(ALL) NOPASSWD: ALL
Q: Comment sortir explicitement de la session "sudo"?
sudo -K
Q: Comment changer les permissions des fichiers/dossiers?
Clic droit sur le fichier/dossier -> Propriétés Onglet Permissions -> Lire/Ecrire/Exécuter (Cocher les permissions Propriétaire/Groupe/Autre)
Q: Comment attribuer des fichiers/dossiers à un utilisateur?
sudo chown nom_de_l'utilisateur /emplacement_des_fichiers_ou_dossiers
Q: Comment attribuer des fichiers/dossiers à un groupe?
sudo chgrp nom_du_groupe /emplacement_des_fichiers_ou_dossiers
Q: Quelles sont les choses à connaître concernant la sécurité sous Ubuntu?
Q: Comment désactiver le menu d'édition de GRUB?
grub grub> md5crypt Password: ****** (ubuntu) Encrypted: $1$ZWnke0$1fzDBVjUcT1Mpdd4u/T961 (mot de passe crypté) grub> quit sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup sudo gedit /boot/grub/menu.lst
... ## password ['--md5'] passwd # If used in the first section of a menu file, disable all interactive editing # control (menu entry editor and command-line) and entries protected by the # command 'lock' # e.g. password topsecret # password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/ # password topsecret ...
password --md5 $1$ZWnke0$1fzDBVjUcT1Mpdd4u/T961 (mot de passe crypté au dessus)
... title Ubuntu, kernel 2.6.10-5-386 (recovery mode) root (hd0,1) kernel /boot/vmlinuz-2.6.10-5-386 root=/dev/hda2 ro single initrd /boot/initrd.img-2.6.10-5-386 savedefault boot ...
#title Ubuntu, kernel 2.6.10-5-386 (recovery mode) #root (hd0,1) #kernel /boot/vmlinuz-2.6.10-5-386 root=/dev/hda2 ro single #initrd /boot/initrd.img-2.6.10-5-386 #savedefault #boot
Q: Comment désactiver l'historique du mode Terminal?
rm $HOME/.bash_history touch $HOME/.bash_history chmod 000 $HOME/.bash_history
Q: Comment empécher que Ctrl+Alt+Suppr ne redémarre l'ordinateur en mode Terminal?
sudo cp /etc/inittab /etc/inittab_backup sudo gedit /etc/inittab
... ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now ...
#ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now
sudo telinit q
sudo cp /etc/bash.bashrc /etc/bash.bashrc_backup sudo gedit /etc/bash.bashrc
alias rm='rm -i' alias cp='cp -i' alias mv='mv -i'
Q: Comment avoir un accès à l'ordinateur en root sans s'identifier?
Ubuntu, kernel 2.6.10-5-386 (recovery mode)
Q: Comment modifier les options de démarrage du noyau pour obtenir un accès root?
Ubuntu, kernel 2.6.10-5-386
kernel /boot/vmlinuz-2.6.10-5-386 root=/dev/hda2 ro quiet splash
grub edit> kernel /boot/vmlinuz-2.6.10-5-386 root=/dev/hda2 ro quiet splash rw init=/bin/bash
Q: Comment utiliser le CD d'installation de Ubuntu pour avoir un accès root?
boot: rescue
Q: Comment changer le mot de passe root ou utilisateur si vous l'avez oublié?
passwd root
passwd login_utilisateur
Q: Comment changer le mot de passe de GRUB si vous l'avez oublié?
grub grub> md5crypt Password: ****** (ubuntu) Encrypted: $1$ZWnke0$1fzDBVjUcT1Mpdd4u/T961 (mot de passe crypté) grub> quit sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup sudo gedit /boot/grub/menu.lst
... password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/ ...
password --md5 $1$ZWnke0$1fzDBVjUcT1Mpdd4u/T961 (mot de passe crypté au dessus)
Q: Comment restaurer GRUB après une installation de Windows?
Par ex. Admettons que /dev/hda soit le point de montage de la partition /boot
grub-install /dev/hda
Q: Comment ajouter une entrée pour Windows dans GRUB?
Par ex. Admettons que /dev/hda1 soitle point de montage de la partition Windows
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup sudo gedit /boot/grub/menu.lst
title Microsoft Windows root (hd0,0) savedefault makeactive chainloader +1
Q: Comment lire une partition GNU/Linux (ext2, ext3) avec Windows?
Q: Comment activer le pavé numérique au démarrage de GNOME?
sudo apt-get install numlockx sudo cp /etc/X11/gdm/Init/Default /etc/X11/gdm/Init/Default_backup sudo gedit /etc/X11/gdm/Init/Default
... exit 0
if [ -x /usr/bin/numlockx ]; then /usr/bin/numlockx on fi
Q: Comment redémarrer GNOME sans redémarrer l'ordinateur?
Appuyer sur 'Ctrl + Alt + Ret. arrièrou
sudo /etc/init.d/gdm restart
Q: Comment lancer des programmes au démarrage de GNOME?
Onglet Programmes au démarrage -> Ajouter/Editer/Supprimer
Q: Comment passer en mode console depuis GNOME?
Appuyer sur 'Ctrl + Alt + F1' (F2 - F6)
Appuyer sur 'Ctrl + Alt + F7
Q: Comment désactiver Ctrl+Alt+Backspace de redémarrer X avec GNOME?
sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf_backup sudo gedit /etc/X11/xorg.conf
Section "ServerFlags" Option "DontZap" "yes" EndSection
Q: Comment rafraîchir le bureau GNOME?
killall nautilus
Q: Comment rafraîchir les barres GNOME?
killall gnome-panel
Q: Comment ouvrir les répertoires dans la même fenêtre avec Nautilus?
/ -> apps -> nautilus -> preferences -> always_use_browser (Coché)
Appuyer sur 'Ctrl + H'
Menu édition -> Préférences Onglet Vues -> Vue par défaut -> Afficher les fichiers cachés et de sauvegarde (Coché)
Q: Comment parcourir les fichiers/dossiers en tant qu'utilisateur root dans Nautilus?
sudo gedit /usr/share/applications/Nautilus-root.desktop
[Desktop Entry] Name=Explorateur de fichier (Root) Comment=Parcourir le système de fichiers en tant que root Exec=gksudo "nautilus --browser %U" Icon=file-manager Terminal=false Type=Application Categories=Application;System;
Q: Comment afficher les icônes "Poste de travail", "Dossier personnel", "Corbeille" sur le bureau?
/ -> apps -> nautilus -> desktop -> computer_icon_visible (Coché) home_icon_visible (Coché) trash_icon_visible (Coché)
Q: Comment changer les programmes par défaut du menu "Ouvrir avec"?
Clic droit sur le fichier -> Propriétés Onglet Ouvrir avec -> Ajouter Sélectionner le programme Sélectionner le programme choisi (Coché)
Q: Comment mettre Mozilla Thunderbird comme client mail par défaut?
Onglet Courrier électronique -> Lecteur par défaut -> Commande: mozilla-thunderbird %s
Q: Comment ouvrir des fichiers en tant que root via le menu contextuel?
gedit $HOME/.gnome2/nautilus-scripts/Ouvrir\ comme\ root
for uri in $NAUTILUS_SCRIPT_SELECTED_URIS; do gnome-sudo "gnome-open $uri" & done
chmod +x $HOME/.gnome2/nautilus-scripts/Ouvrir\ comme\ root
Clic droit sur le fichier -> Scripts -> Ouvrir comme root
Q: Comment désactiver le bip système en mode Terminal?
Menu édition -> Profile courant... Onglet Général -> Général -> "Bip" du Terminal (Décoché)
Q: Comment rendre l'accès aux sites Web plus rapide dans Mozilla Firefox?
Barre d'adresse -> about:config Filtre: -> network.dns.disableIPv6 -> true network.http.pipelining -> true network.http.pipelining.maxrequests -> 8 network.http.proxy.pipelining -> true
Q: Comment désactiver le bip système lors de la recherche de lien de Mozilla Firefox?
Barre d'adresse -> about:config Filtre: -> accessibility.typeaheadfind.enablesound -> false
Q: Comment restaurer les icônes originales de Mozilla Firefox?
wget -c http://frankandjacq.com/ubuntuguide/mozilla-firefox.png wget -c http://frankandjacq.com/ubuntuguide/document.png chmod 644 mozilla-firefox.png chmod 644 document.png sudo dpkg-divert --rename /usr/share/pixmaps/mozilla-firefox.png sudo dpkg-divert --rename /usr/share/pixmaps/mozilla-firefox.xpm sudo dpkg-divert --rename /usr/lib/mozilla-firefox/icons/default.xpm sudo dpkg-divert --rename /usr/lib/mozilla-firefox/icons/document.png sudo dpkg-divert --rename /usr/lib/mozilla-firefox/chrome/icons/default/default.xpm sudo cp mozilla-firefox.png /usr/share/pixmaps/mozilla-firefox.png sudo cp mozilla-firefox.png /usr/share/pixmaps/mozilla-firefox.xpm sudo cp mozilla-firefox.png /usr/lib/mozilla-firefox/icons/default.xpm sudo cp document.png /usr/lib/mozilla-firefox/icons/document.png sudo cp mozilla-firefox.png /usr/lib/mozilla-firefox/chrome/icons/default/default.xpm
Q: Comment restaurer les icônes originales de Mozilla Thunderbird?
wget -c http://frankandjacq.com/ubuntuguide/mozilla-thunderbird.xpm chmod 644 mozilla-thunderbird.xpm sudo dpkg-divert --rename /usr/share/pixmaps/mozilla-thunderbird.xpm sudo dpkg-divert --rename /usr/share/pixmaps/mozilla-thunderbird-menu.xpm sudo dpkg-divert --rename /usr/share/pixmaps/mozilla-thunderbird-pm-menu.xpm sudo dpkg-divert --rename /usr/lib/mozilla-thunderbird/chrome/icons/default/mozilla-thunderbird.xpm sudo dpkg-divert --rename /usr/lib/mozilla-thunderbird/chrome/icons/default/messengerWindow16.xpm sudo dpkg-divert --rename /usr/lib/mozilla-thunderbird/chrome/icons/default/messengerWindow.xpm sudo dpkg-divert --rename /usr/lib/mozilla-thunderbird/chrome/icons/default/default.xpm sudo cp mozilla-thunderbird.xpm /usr/share/pixmaps/mozilla-thunderbird.xpm sudo cp mozilla-thunderbird.xpm /usr/share/pixmaps/mozilla-thunderbird-menu.xpm sudo cp mozilla-thunderbird.xpm /usr/share/pixmaps/mozilla-thunderbird-pm-menu.xpm sudo cp mozilla-thunderbird.xpm /usr/lib/mozilla-thunderbird/chrome/icons/default/mozilla-thunderbird.xpm sudo cp mozilla-thunderbird.xpm /usr/lib/mozilla-thunderbird/chrome/icons/default/messengerWindow16.xpm sudo cp mozilla-thunderbird.xpm /usr/lib/mozilla-thunderbird/chrome/icons/default/messengerWindow.xpm sudo cp mozilla-thunderbird.xpm /usr/lib/mozilla-thunderbird/chrome/icons/default/default.xpm
Q: Comment utiliser facilement apt-get (Synaptic)?
Menu Edition -> Recharger les informations sur les paquets
Menu Edition -> Tout mettre à jour... -> Mise à jour par défaut Menu Edition -> Appliquer les modifications
Menu Edition -> Recherche... Spécifier le nom du paquet
Sélection de "nom_du_paquet" Menu Paquet -> Sélectionné pour installation Menu Edition -> Appliquer les modifications
Sélection de "nom_du_paquet" Menu Paquet -> Selectionné pour suppression Menu Edition -> Appliquer les modifications
Q: Comment installer/supprimer un paquet via un fichier .deb?
sudo dpkg -i package_file.deb
sudo dpkg -r package_name
Q: Comment convertir un fichier .rpm en fichier .deb?
sudo alien package_file.rpm
Q: Comment renommer tous les fichiers d'un dossier en une fois?
wget -c http://frankandjacq.com/ubuntuguide/mvb_1.6.tgz sudo tar zxvf mvb_1.6.tgz -C /usr/ sudo chown -R root:root /usr/mvb_1.6/ sudo ln -fs /usr/mvb_1.6/mvb /usr/bin/mvb mvb -h
Q: Comment sauver le contenu d'une commande "man" dans un fichier?
man command | col -b > fichier.txt
Q: Comment générer l'empreinte MD5 d'un fichier?
md5sum fichier.iso > fichier.iso.md5
Q: Comment vérifier l'empreinte MD5 d'un fichier?
Par ex. Admettons que fichier.iso et fichier.iso.md5 sont dans le même dossier
md5sum -c fichier.iso.md5
Q: Comment monter/démonter un fichier image (ISO) sans gravure?
sudo mkdir /media/iso sudo modprobe loop sudo mount fichier.iso /media/iso/ -t iso9660 -o loop
sudo umount /media/iso/
Q: Comment cacher le menu GRUB au démarrage?
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup sudo gedit /boot/grub/menu.lst
... #hiddenmenu ...
hiddenmenu
Q: Comment changer le temps d'attente au démarrage de GRUB?
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup sudo gedit /boot/grub/menu.lst
... timeout 3 ...
timeout X_secondes
Q: Comment changer le système d'exploitation par défaut dans le menu GRUB?
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup sudo gedit /boot/grub/menu.lst
... default 0 ...
default X_sequence
Q: Comment afficher une image de démarrage pour le menu GRUB au démarrage?
e.g. Supposons que hd0,1 est la partition boot de Ubuntu
wget -c http://frankandjacq.com/ubuntuguide/ubuntu.xpm.gz chmod 644 ubuntu.xpm.gz sudo mkdir /boot/grub/images sudo cp ubuntu.xpm.gz /boot/grub/images/ sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup sudo gedit /boot/grub/menu.lst
# menu.lst - See: grub(8), info grub, update-grub(8) # grub-install(8), grub-floppy(8), # grub-md5-crypt, /usr/share/doc/grub # and /usr/share/doc/grub-doc/. ...
splashimage (hd0,1)/boot/grub/images/ubuntu.xpm.gz
Q: Comment convertir une image de fond en image de démarrage pour GRUB?
e.g. Supposons que wallpaper.png est l'image de fond à convertir splashimage.xpm.gz est l'image de démarrage pour le menu GRUB
convert -resize 640x480 -colors 14 wallpaper.png splashimage.xpm && gzip splashimage.xpm
Q: Comment désactiver temporairement un service au démarrage?
Appuyer sur 'Ctrl + C'
Q: Comment désactiver définitivement un service au démarrage?
sudo chmod -x /etc/init.d/nom_du_service
sudo chmod +x /etc/init.d/nom_du_service
Q: Comment créer des variables système?
sudo cp /etc/bash.bashrc /etc/bash.bashrc_backup sudo gedit /etc/bash.bashrc
Q: Comment nettoyer le contenu du dossier /tmp/ à l'arrêt du système?
sudo cp /etc/init.d/sysklogd /etc/init.d/sysklogd_backup sudo gedit /etc/init.d/sysklogd
... stop) log_begin_msg "Stopping system log daemon..." start-stop-daemon --stop --quiet --oknodo --exec $binpath --pidfile $pidfile log_end_msg $? ...
rm -fr /tmp/* /tmp/.??*
Q: Comment installer le serveur antivirus ClamAV?
sudo apt-get install clamav
Q: Comment mettre à jour la base de données antivirus manuellement?
sudo freshclam
Q: Comment scanner manuellement des fichiers/dossiers pour rechercher des virus?
sudo clamscan -r /emplacement_des_fichiers_ou_dossiers
Q: Comment scanner automatiquement des fichiers/dossiers pour rechercher des virus?
Par ex. scanner automatiquement les fichiers/répertoires tous les jours à minuit * * * * * signifie minute heure date mois année
export EDITOR=gedit && sudo crontab -e
00 00 * * * sudo clamscan -r /emplacement_des_fichiers_ou_dossiers
Q: Comment installer le serveur Samba pour partager des fichiers/dossiers?
sudo apt-get install samba sudo apt-get install smbfs
Q: Comment ajouter/éditer/supprimer des utilisateurs réseau?
smbpasswd -a system_username sudo gedit /etc/samba/smbusers
system_username = "network username"
sudo smbpasswd -a system_username
sudo smbpasswd -x system_username
Q: Comment partager des dossiers en lecture seule (Authentication activée)?
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... ; security = user ...
security = user username map = /etc/samba/smbusers
sudo testparm sudo /etc/init.d/samba restart
Q: Comment partager des dossiers en lecture/écriture (Authentication activée)?
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... ; security = user ...
security = user username map = /etc/samba/smbusers
... # By default, the home directories are exported read-only. Change next # parameter to 'yes' if you want to be able to write to them. writable = no ...
# By default, the home directories are exported read-only. Change next # parameter to 'yes' if you want to be able to write to them. writable = yes
sudo testparm sudo /etc/init.d/samba restart
Q: Comment partager des dossiers en lecture seule pour un groupe (Authentication activée)?
sudo mkdir /home/group sudo chmod 777 /home/group/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... ; security = user ...
security = user username map = /etc/samba/smbusers
[Group] comment = Group Folder path = /home/group public = yes writable = no valid users = system_username1 system_username2 create mask = 0700 directory mask = 0700 force user = nobody force group = nogroup
sudo testparm sudo /etc/init.d/samba restart
Q: Comment partager des dossiers en lecture/écriture pour un groupe (Authentication activée)?
sudo mkdir /home/group sudo chmod 777 /home/group/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... ; security = user ...
security = user username map = /etc/samba/smbusers
[Group] comment = Group Folder path = /home/group public = yes writable = yes valid users = system_username1 system_username2 create mask = 0700 directory mask = 0700 force user = nobody force group = nogroup
sudo testparm sudo /etc/init.d/samba restart
Q: Comment partager des dossiers en lecture seule à tout le monde (Authentication activée)?
sudo mkdir /home/public sudo chmod 777 /home/public/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... ; security = user ...
security = user username map = /etc/samba/smbusers
[public] comment = Public Folder path = /home/public public = yes writable = no create mask = 0777 directory mask = 0777 force user = nobody force group = nogroup
sudo testparm sudo /etc/init.d/samba restart
Q: Comment partager des dossiers en lecture/écriture à tout le monde (Authentication activée)?
sudo mkdir /home/public sudo chmod 777 /home/public/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... ; security = user ...
security = user username map = /etc/samba/smbusers
[public] comment = Public Folder path = /home/public public = yes writable = yes create mask = 0777 directory mask = 0777 force user = nobody force group = nogroup
sudo testparm sudo /etc/init.d/samba restart
Q: Comment partager des dossiers en lecture seule à tout le monde (Authentication désactivée)?
sudo mkdir /home/public sudo chmod 777 /home/public/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... ; security = user ...
security = share
[public] comment = Public Folder path = /home/public public = yes writable = no create mask = 0777 directory mask = 0777 force user = nobody force group = nogroup
sudo testparm sudo /etc/init.d/samba restart
Q: Comment partager des dossiers en lecture/écriture à tout le monde (Authentication désactivée)?
sudo mkdir /home/public sudo chmod 777 /home/public/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup sudo gedit /etc/samba/smb.conf
... ; security = user ...
security = share
[public] comment = Public Folder path = /home/public public = yes writable = yes create mask = 0777 directory mask = 0777 force user = nobody force group = nogroup
sudo testparm sudo /etc/init.d/samba restart
Q: Comment installer un serveur SSH pour administrer à distance?
sudo apt-get install ssh
Q: Comment se connecter en SSH à une machine Ubuntu distante?
Par ex. Admettons que l'ordinateur distant Ubuntu ait le serveur SSH d'installé Lire Comment installer un serveur SSH pour administrer à distance? Adresse IP de la machine distante Ubuntu: 192.168.0.1
ssh username@192.168.0.1
Par ex. Admettons que l'ordinateur distant Ubuntu ait le serveur SSH d'installé Lire Comment installer un serveur SSH pour administrer à distance? Adresse IP de la machine distante Ubuntu: 192.168.0.1 Emplacement des fichiers/dossiers distants: /home/username/remotefile.txt Emplacement de sauvegarde de la machine locale: . (Répertoire courant)
scp -r username@192.168.0.1:/home/username/remotefile.txt .
Par ex. Admettons que l'ordinateur distant Ubuntu ait le serveur SSH d'installé Lire Comment installer un serveur SSH pour administrer à distance? Emplacement des fichiers/dossiers de la machine locale: localfile.txt Adresse IP de la machine distante Ubuntu: 192.168.0.1 Emplacement de sauvegarde de la machine distante: /home/username/
scp -r localfile.txt username@192.168.0.1:/home/username/
Par ex. Admettons que l'ordinateur distant Ubuntu ait le serveur SSH d'installé Lire Comment installer un serveur SSH pour administrer à distance? Adresse IP de la machine distante Ubuntu: 192.168.0.1 Emplacement des fichiers/dossiers de la machine distante: /home/username/remotefile.txt Emplacement de sauvegarde de la machine locale: . (Répertoire courant)
rsync -v -u -a --delete --rsh=ssh --stats username@192.168.0.1:/home/username/remotefile.txt .
Par ex. Admettons que l'ordinateur distant Ubuntu ait le serveur SSH d'installé Lire Comment installer un serveur SSH pour administrer à distance? Emplacement des fichiers/dossiers de la machine locale: localfile.txt Adresse IP de la machine distante Ubuntu: 192.168.0.1 Emplacement de sauvegarde de la machine distante: /home/username/
rsync -v -u -a --delete --rsh=ssh --stats localfile.txt username@192.168.0.1:/home/username/
Q: Comment se connecter en SSH à une machine Ubuntu distante depuis Windows?
Par ex. Admettons que l'ordinateur distant Ubuntu ait le serveur SSH d'installé Lire Comment installer un serveur SSH pour administrer à distance?
Q: Comment copier des fichiers/dossiers depuis/vers une machine Ubuntu distante depuis Windows?
Par ex. Admettons que l'ordinateur distant Ubuntu ait le serveur SSH d'installé Lire Comment installer un serveur SSH pour administrer à distance?
Q: Comment installer un serveur DHCP pour assigner automatiquement les adresses IP du réseau local?
Par ex. Admettons que "eth0" soit l'interface de la carte réseau Plage d'adresses IP: 192.168.0.100 à 192.168.0.200 Masque de sous réseau: 255.255.255.0 Serveurs DNS: 202.188.0.133, 202.188.1.5 Domaines: tm.net.my Adresse de la passerelle: 192.168.0.1
sudo apt-get install dhcp3-server sudo cp /etc/default/dhcp3-server /etc/default/dhcp3-server_backup sudo gedit /etc/default/dhcp3-server
... INTERFACES=""
INTERFACES="eth0"
sudo cp /etc/dhcp3/dhcpd.conf /etc/dhcp3/dhcpd.conf_backup sudo gedit /etc/dhcp3/dhcpd.conf
... # option definitions common to all supported networks... option domain-name "example.org"; option domain-name-servers ns1.example.org, ns2.example.org; default-lease-time 600; max-lease-time 7200; ...
# option definitions common to all supported networks... #option domain-name "example.org"; #option domain-name-servers ns1.example.org, ns2.example.org; #default-lease-time 600; #max-lease-time 7200;
... # A slightly different configuration for an internal subnet. #subnet 10.5.5.0 netmask 255.255.255.224 { # range 10.5.5.26 10.5.5.30; # option domain-name-servers ns1.internal.example.org; # option domain-name "internal.example.org"; # option routers 10.5.5.1; # option broadcast-address 10.5.5.31; # default-lease-time 600; # max-lease-time 7200; #} ...
# A slightly different configuration for an internal subnet. subnet 192.168.0.0 netmask 255.255.255.0 { range 192.168.0.100 192.168.0.200; option domain-name-servers 202.188.0.133, 202.188.1.5; option domain-name "tm.net.my"; option routers 192.168.0.1; option broadcast-address 192.168.0.255; default-lease-time 600; max-lease-time 7200; }
sudo /etc/init.d/dhcp3-server restart
Q: Comment installer un serveur de base de données MySQL?
sudo apt-get install mysql-server mysqladmin -u root password db_user_password
Q: Comment installer MySQL Control Center?
sudo apt-get install mysqlcc sudo gedit /usr/share/applications/MySQLCC.desktop
[Desktop Entry] Name=MySQLCC Comment=MySQLCC Exec=mysqlcc Icon=/usr/share/pixmaps/mysqlcc.xpm Terminal=false Type=Application Categories=Application;System;
Q: Comment installer le serveur HTTP Apache (Web)?
sudo apt-get install apache2
Q: Comment installer PHP pour le serveur HTTP Apache?
sudo apt-get install php4 sudo gedit /var/www/testphp.php
<?php phpinfo(); ?>
Q: Comment installer MySQL pour le serveur HTTP Apache?
sudo apt-get install libapache2-mod-auth-mysql sudo apt-get install php4-mysql sudo /etc/init.d/apache2 restart
Q: Comment lier des URLs à des répertoires en dehors de /var/www/?
sudo gedit /etc/apache2/conf.d/alias
Alias /URL-path /location_of_folder/ <Directory /location_of_folder/> Options Indexes FollowSymLinks AllowOverride All Order allow,deny Allow from all </Directory>
sudo /etc/init.d/apache2 restart
Q: Comment changer le port par défaut pour le serveur HTTP Apache?
Par ex. Admettons que le nouveau port est 79
sudo cp /etc/apache2/ports.conf /etc/apache2/ports.conf_backup sudo gedit /etc/apache2/ports.conf
Listen 80
Listen 79
sudo /etc/init.d/apache2 restart
Q: Comment naviguer avec le port du serveur HTTP Apache changé dans Mozilla Firefox?
Par ex. Admettons que le nouveau port est 79
sudo cp /usr/lib/mozilla-firefox/greprefs/all.js /usr/lib/mozilla-firefox/greprefs/all.js_backup sudo gedit /usr/lib/mozilla-firefox/greprefs/all.js
... // If there is ever a security firedrill that requires // us to block certian ports global, this is the pref // to use. Is is a comma delimited list of port numbers // for example: // pref("network.security.ports.banned", "1,2,3,4,5"); // prevents necko connecting to ports 1-5 unless the protocol // overrides. ...
pref("network.security.ports.banned.override", "79");
e.g. /var/music/ est le répertoire par défaut
sudo apt-get install gnump3d
Q: Comment changer le répertoire par défaut qui contient les fichiers multimédia pour GNUMP3d?
e.g. /home/music/ est le répertoire qui contient les fichiers multimédia
sudo cp /etc/gnump3d/gnump3d.conf /etc/gnump3d/gnump3d.conf_backup sudo gedit /etc/gnump3d/gnump3d.conf
root = /var/music
root = /home/music
user = gnump3d
user = root
sudo /etc/init.d/gnump3d restart
Q: How to change the default port number for GNUMP3d?
e.g. Assumons que le nouveau port est 7878
sudo cp /etc/gnump3d/gnump3d.conf /etc/gnump3d/gnump3d.conf_backup sudo gedit /etc/gnump3d/gnump3d.conf
port = 8888
port = 7878
sudo /etc/init.d/gnump3d restart
Q: Configuration des interfaces réseau... (prend trop de temps à se charger)
Q: Synchronisation de l'horloge avec ntp.ubuntulinux.org... (prend trop de temps à se charger)
service_name = ntpdate
Q: Comment éviter que l'horloge système soit mise en UTC (GMT)?
sudo cp /etc/default/rcS /etc/default/rcS_backup sudo gedit /etc/default/rcS
... UTC=yes ...
UTC=no
Configurer correctement la date et l'heure
sudo /etc/init.d/hwclock.sh restart
Q: Comment configurer correctement le son dans GNOME?
sudo killall esd sudo cp /etc/esound/esd.conf /etc/esound/esd.conf_backup sudo gedit /etc/esound/esd.conf
... auto_spawn=0 spawn_options=-terminate -nobeeps -as 5 ...
auto_spawn=1 spawn_options=-terminate -nobeeps -as 2 -d default
sudo apt-get install libesd-alsa0 sudo gedit /etc/asound.conf
pcm.card0 { type hw card 0 } pcm.!default { type plug slave.pcm "dmixer" } pcm.dmixer { type dmix ipc_key 1025 slave { pcm "hw:0,0" period_time 0 period_size 2048 buffer_size 32768 rate 48000 } bindings { 0 0 1 1 } }
sudo ln -fs /usr/lib/libesd.so.0 /usr/lib/libesd.so.1
Onglet Général -> Sons pour les événements (Décoché)
Q: Comment forcer le vidage de la corbeille dans GNOME?
sudo rm -rf $HOME/.Trash/
Q: Comment supprimer des entrées de menu à double dans GNOME?
rm -rf $HOME/.config/menus/applications.menu
sudo /etc/init.d/dbus-1 restart
Q: Comment upgrader de Hoary Hedgehog à Breezy Badger (expérimental)?
Attention! Breezy Badger est toujours en développement. A utiliser seulement pour des tests Upgrader pourrait compromettre votre système.
sudo cp /etc/apt/sources.list /etc/apt/sources.list_backup sudo gedit /etc/apt/sources.list
deb cdrom:[Ubuntu 5.04 _Hoary Hedgehog_ - Release i386 (20050407)]/ hoary main restricted ## Uncomment the following two lines to fetch updated software from the network # deb http://us.archive.ubuntu.com/ubuntu hoary main restricted # deb-src http://us.archive.ubuntu.com/ubuntu hoary main restricted ## Uncomment the following two lines to fetch major bug fix updates produced ## after the final release of the distribution. # deb http://us.archive.ubuntu.com/ubuntu hoary-updates main restricted # deb-src http://us.archive.ubuntu.com/ubuntu hoary-updates main restricted ## Uncomment the following two lines to add software from the 'universe' ## repository. ## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu ## team, and may not be under a free licence. Please satisfy yourself as to ## your rights to use the software. Also, please note that software in ## universe WILL NOT receive any review or updates from the Ubuntu security ## team. # deb http://us.archive.ubuntu.com/ubuntu hoary universe # deb-src http://us.archive.ubuntu.com/ubuntu hoary universe # deb http://security.ubuntu.com/ubuntu hoary-security main restricted # deb-src http://security.ubuntu.com/ubuntu hoary-security main restricted # deb http://security.ubuntu.com/ubuntu hoary-security universe # deb-src http://security.ubuntu.com/ubuntu hoary-security universe
#deb cdrom:[Ubuntu 5.04 _Hoary Hedgehog_ - Release i386 (20050407)]/ hoary main restricted ## Uncomment the following two lines to fetch updated software from the network deb http://us.archive.ubuntu.com/ubuntu breezy main restricted deb-src http://us.archive.ubuntu.com/ubuntu breezy main restricted ## Uncomment the following two lines to fetch major bug fix updates produced ## after the final release of the distribution. deb http://us.archive.ubuntu.com/ubuntu breezy-updates main restricted deb-src http://us.archive.ubuntu.com/ubuntu breezy-updates main restricted ## Uncomment the following two lines to add software from the 'universe' ## repository. ## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu ## team, and may not be under a free licence. Please satisfy yourself as to ## your rights to use the software. Also, please note that software in ## universe WILL NOT receive any review or updates from the Ubuntu security ## team. deb http://us.archive.ubuntu.com/ubuntu breezy universe deb-src http://us.archive.ubuntu.com/ubuntu breezy universe deb http://security.ubuntu.com/ubuntu breezy-security main restricted deb-src http://security.ubuntu.com/ubuntu breezy-security main restricted deb http://security.ubuntu.com/ubuntu breezy-security universe deb-src http://security.ubuntu.com/ubuntu breezy-security universe deb http://archive.ubuntu.com/ubuntu breezy multiverse deb-src http://archive.ubuntu.com/ubuntu breezy multiverse
sudo apt-get update sudo apt-get dist-upgrade
Le logo Ubuntu, Ubuntu et Canonical sont des marques déposées de Canonical Ltd.