informatique:linux:commandes_linux
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
informatique:linux:commandes_linux [2020/12/15 15:31] – [date] comaprer des dates pteu | informatique:linux:commandes_linux [2020/12/24 09:21] – [tee] pteu | ||
---|---|---|---|
Line 1107: | Line 1107: | ||
ymir | ymir | ||
</ | </ | ||
+ | |||
+ | =====iconv===== | ||
+ | |||
+ | iconv est un utilitaire de conversion et d' | ||
+ | <code bash> | ||
+ | # Supprimer les caractères accentués: | ||
+ | echo " | ||
+ | eei | ||
+ | </ | ||
+ | |||
=====id===== | =====id===== | ||
Line 1234: | Line 1244: | ||
=====ip===== | =====ip===== | ||
- | Couteau suisse réseau, il permet de configurer les paramètres ip d'une interface réseau. | + | Couteau suisse réseau, il permet de configurer les paramètres ip d'une interface réseau. Dans de plus en plus de distributions, |
<code bash> | <code bash> | ||
# afficher les interfaces | # afficher les interfaces | ||
Line 1262: | Line 1272: | ||
</ | </ | ||
+ | Équivalence anciennes/ | ||
+ | ^ anciennes commandes ^ équivalent ip ^ | ||
+ | | ifconfig -a | ip a | | ||
+ | | ifconfig enp6s0 down | ip link set enp6s0 down | | ||
+ | | ifconfig enp6s0 up | ip link set enp6s0 up | | ||
+ | | ifconfig enp6s0 10.0.0.24 netmask 255.255.255.0 dev enp6s0 | ip addr add 10.0.0.24/ | ||
+ | | ifconfig enp6s0 mtu 9000 | ip link set enp6s0 mtu 9000 | | ||
+ | | ifconfig enp6s0:0 10.0.0.25 | ip addr add 10.0.0.25/ | ||
+ | | netstat | ss | | ||
+ | | netstat -tulpn | ss -tulpn | | ||
+ | | netstat -neopa | ss -neopa | | ||
+ | | netstat -g | ip maddr | | ||
+ | | route | ip r | | ||
+ | | route add -net 10.0.0.0 netmask 255.255.255.0 dev enp6s0 | ip route add 10.0.0.0/24 dev enp6s0 | | ||
+ | | route add default gw 10.0.0.254 | ip route add default via 10.0.0.254 | | ||
+ | | arp -a | ip neigh | | ||
+ | | arp -v | ip -s neigh | | ||
+ | | arp -s 10.0.0.33 1:2:3:4:5:6 | ip neigh add 10.0.1.33 lladdr 1:2:3:4:5:6 dev enp6s0 | | ||
+ | | arp -i enp6s0 -d 10.0.0.254 | ip neigh del 10.0.0.254 dev wlp7s0 | | ||
=====ipcs===== | =====ipcs===== | ||
Line 2593: | Line 2622: | ||
Un outil d' | Un outil d' | ||
- | par exemple on veut archiver le répertoire ./toto/ et tout son contenu (répertoires et fichiers normaux). | ||
- | tar cvf toto.tar ./toto | ||
- | (// | ||
- | On peut archiver | + | <code bash> |
- | tar czvf toto.tar.gz ./toto | + | # pour archiver le répertoire ./toto/ et tout son contenu |
+ | # (toto.tar désigne le nom de l'archive qu'on veut créer, il doit avoir l' | ||
+ | tar cvf toto.tar ./toto | ||
- | Plus tar__d__, pour le désarchiver : | + | # archiver ET compresser le fichier grâce à gunzip (-z) ou bunzip (-y) : |
- | tar zxf toto.tar | + | # -c pour compresser, -v pour un affichage verbeux, -f pour préciser |
+ | tar czvf toto.tar.gz ./toto | ||
+ | # extraire (-x) le contenu d'une archive gunzip (-z) : | ||
+ | tar zxf toto.tar | ||
+ | </ | ||
+ | |||
+ | =====tee===== | ||
+ | |||
+ | Permet de copier l' | ||
+ | <code bash> | ||
+ | $ echo toto | tee fic.log | ||
+ | toto | ||
+ | |||
+ | $ echo titi | tee -a fic.log | ||
+ | titi | ||
+ | |||
+ | $ cat fic.log | ||
+ | toto | ||
+ | titi | ||
+ | </ | ||
=====telnet===== | =====telnet===== |
informatique/linux/commandes_linux.txt · Last modified: 2024/04/05 06:58 by pteu