Table des matières
0 billet(s) pour février 2026
Compilation du module Python PySVN sous RedHat
Compilation
sudo yum groupinstall "Development Tools" sudo yum install python2-devel subversion-devel mkdir ~/compile cd !$ export http_proxy=http://127.0.0.1:3128 export https_proxy=http://127.0.0.1:3128 wget https://downloads.sourceforge.net/project/pysvn/pysvn/V1.9.11/pysvn-1.9.11.tar.gz tar xf pysvn-1.9.11.tar.gz cd ~/compile/pysvn-1.9.11/Import/pycxx-7.1.3 #./build-all.sh ./build-unlimited-api.sh python2.7 #python setup.py install cd ~/compile/pysvn-1.9.11/Source ln -s ~/compile/pysvn-1.9.11/Import/pycxx-7.1.3/Src Src #./build.sh python2 setup.py configure --enable-debug --verbose --pycxx-dir=$HOME/compile/pysvn-1.9.11/Import/pycxx-7.1.3 make -j $(nproc)
Test
env PYTHONPATH=$PWD python2 <<< "import pysvn"
Installation
sudo cp -r ~/compile/pysvn-1.9.11/Source/pysvn /usr/lib64/python2.7/
Commande mail - SMTP client MUA Mail User Agent
Voir aussi :
- ssmtp / msmtp / /usr/sbin/sendmail
- LMTP
- curl smtp / smtps
echo -e "Chers collègues je vous offre les croissants et du chocolat pour mardi de Pâques\n\nCordialement,\nPierre Dupont" |mail -r 'pierre.dupont@acme.fr (Pierre Dupont)' -s "Croissants !" toutelequipe@acme.fr touslescopains@acme.fr pierre.dupont@acme.fr
Voir : https://www.croissantage.fr/
echo "plop" |mail -s "Sujet" contact@acme.fr -aFrom:root@acme.fr echo "plop" |mutt -e 'my_hdr From:root@acme.fr' -s "Sujet" contact@acme.fr
cat << EOM |sendmail -it -f test@acme.fr From:test@acme.fr To: <contact@plop.com> Subject: Sujet Message EOM
En encore avec curl
curl --mail-from phil@mydmn.org --mail-rcpt bob@mydmn.org smtp://srv-smtp.mydmn.org
Autre
echo Test 1 |mail -v -s "Test 1" testmail@acme.fr Resolving host fed-smtp.acme.fr . . . done. Connecting to 192.168.1.12:smtp . . . connected. 220 smtp1.localdomain ESMTP Postfix >>> HELO srv1.acme.fr 250 smtp1.localdomain >>> MAIL FROM:<root@srv1.acme.fr> 250 2.1.0 Ok >>> RCPT TO:<testmail@acme.fr> 250 2.1.5 Ok >>> DATA 354 End data with <CR><LF>.<CR><LF> >>> . 250 2.0.0 Ok: queued as 4RTx2c31XTz2Q >>> QUIT 221 2.0.0 Bye
/etc/postfix/main.cf
relayhost = fed-smtp.acme.fr
Yum force pb erreur le fichier de l'installation entre en conflit avec le fichier du paquet
Comment faire un yum --force en trichant un peu
Pb
le fichier /var/www de l'installation de httpd-2.4.6-40.el7.centos.1.x86_64 entre en conflit avec le fichier du paquet plop-1.8.8-2.noarch
Solution
Solution possible : Refaire proprement le package plop
ou forcer ! Nous allons utiliser yumdownloader (packet yum-utils)
yum install yum-utils
yumdownloader httpd rpm -Uvh --force httpd-2.4.6-40.el7.centos.1.x86_64.rpm
Pour que ça marche, il faut faire la même chose avec toutes les dépendances
# yumdownloader --resolve httpd-tools yumdownloader httpd-tools rpm -Uvh --force httpd-2.4.6-40.el7.centos.1.x86_64.rpm httpd-tools-2.4.6-40.el7.centos.1.x86_64.rpm
Coloration des pages man grâce à Most
http://identity-labs.fr/article-5-installation-dun-serveur-lamp-debian-zend-server
Nous allons installer Most, un utilitaire qui ajoute la coloration aux pages de manuel:
apt-get install most
Puis indiquons à man qu'il doit utiliser most
update-alternatives --config pager
Xorg.conf généré par nvidia-xconfig
Voir :
nvidia-xconfig
nvidia-xconfig -a
# nvidia-xconfig: X configuration file generated by nvidia-xconfig
# nvidia-xconfig: version 440.64
Section "ServerLayout"
Identifier "Layout0"
Screen 0 "Screen0"
InputDevice "Keyboard0" "CoreKeyboard"
InputDevice "Mouse0" "CorePointer"
EndSection
Section "Files"
EndSection
Section "InputDevice"
# generated from default
Identifier "Mouse0"
Driver "mouse"
Option "Protocol" "auto"
Option "Device" "/dev/psaux"
Option "Emulate3Buttons" "no"
Option "ZAxisMapping" "4 5"
EndSection
Section "InputDevice"
# generated from default
Identifier "Keyboard0"
Driver "kbd"
EndSection
Section "Monitor"
Identifier "Monitor0"
VendorName "Unknown"
ModelName "Unknown"
Option "DPMS"
EndSection
Section "Device"
Identifier "nvidia"
Driver "nvidia"
VendorName "NVIDIA Corporation"
EndSection
Section "Screen"
Identifier "Screen0"
Device "nvidia"
Monitor "Monitor0"
DefaultDepth 24
SubSection "Display"
Depth 24
EndSubSection
EndSection
Faire fonctionner la carte intégrée pour l'écran
Voir LinuxFr - Utiliser la carte graphique NVIDIA et la carte INTEL intégrée
PS : Xorg est obligé de créer un “Screen” par carte graphique, et qu'un Screen n'est pas un écran physique
- /etc/X11/xorg.conf
Section "ServerLayout" Identifier "Layout0" Screen 0 "Screen1" InputDevice "Keyboard0" "CoreKeyboard" InputDevice "Mouse0" "CorePointer" EndSection Section "Files" EndSection Section "InputDevice" # generated from default Identifier "Mouse0" Driver "mouse" Option "Protocol" "auto" Option "Device" "/dev/psaux" Option "Emulate3Buttons" "no" Option "ZAxisMapping" "4 5" EndSection Section "InputDevice" # generated from default Identifier "Keyboard0" Driver "kbd" EndSection Section "Monitor" Identifier "Monitor0" VendorName "Unknown" ModelName "Unknown" Option "DPMS" EndSection Section "Device" Identifier "nvidia" Driver "nvidia" VendorName "NVIDIA Corporation" #Option "ConstrainCursor" "off" Option "UseDisplayDevice" "none" Option "ProbeAllGpus" "false" Option "AllowEmptyInitialConfiguration" #Option "IgnoreDisplayDevices" "CRT" EndSection Section "Device" Identifier "Intel" BusID "PCI:0:2:0" Driver "modesetting" VendorName "Intel Corporation" #BoardName "Display controller" #ModelName "Device 3e98" #Option "AccelMethod" "SNA" EndSection Section "Screen" Identifier "Screen0" Device "Intel" Monitor "Monitor0" DefaultDepth 24 SubSection "Display" Depth 24 EndSubSection EndSection Section "Screen" Identifier "Screen1" Device "nvidia" EndSection
$ lspci | grep 'Display controller: Intel Corporation Device' | awk -F'[:. ]' '{print $1, $2, $3}' | sed -r 's|0([0-9]) |\1:|g' 0:2:0
https://github.com/Bumblebee-Project/Bumblebee/blob/master/conf/xorg.conf.nvidia
- xorg.conf
Section "ServerLayout" Identifier "Layout0" Option "AutoAddDevices" "false" Option "AutoAddGPU" "false" EndSection Section "Device" Identifier "DiscreteNvidia" Driver "nvidia" VendorName "NVIDIA Corporation" # If the X server does not automatically detect your VGA device, # you can manually set it here. # To get the BusID prop, run `lspci | egrep 'VGA|3D'` and input the data # as you see in the commented example. # This Setting may be needed in some platforms with more than one # nvidia card, which may confuse the proprietary driver (e.g., # trying to take ownership of the wrong device). Also needed on Ubuntu 13.04. # BusID "PCI:01:00:0" # Setting ProbeAllGpus to false prevents the new proprietary driver # instance spawned to try to control the integrated graphics card, # which is already being managed outside bumblebee. # This option doesn't hurt and it is required on platforms running # more than one nvidia graphics card with the proprietary driver. # (E.g. Macbook Pro pre-2010 with nVidia 9400M + 9600M GT). # If this option is not set, the new Xorg may blacken the screen and # render it unusable (unless you have some way to run killall Xorg). Option "ProbeAllGpus" "false" Option "NoLogo" "true" Option "UseEDID" "false" Option "UseDisplayDevice" "none" EndSection
- xorg.conf
Section "ServerLayout" Identifier "layout" Screen 0 "nvidia" #Inactive "intel" # Not supported ? EndSection Section "Device" Identifier "intel" Driver "intel" BusID "PCI:0@0:2:0" Option "AccelMethod" "SNA" EndSection Section "Screen" Identifier "intel" Device "intel" EndSection Section "Device" Identifier "nvidia" Driver "nvidia" BusID "PCI:2@0:0:0" Option "ConstrainCursor" "off" EndSection Section "Screen" Identifier "nvidia" Device "nvidia" Option "AllowEmptyInitialConfiguration" "on" Option "IgnoreDisplayDevices" "CRT" EndSection
- xorg.conf
Section "ServerLayout" Identifier "layout" Screen 0 "nvidia" #Inactive "intel" # Not supported ? EndSection Section "Device" Identifier "nvidia" Driver "nvidia" BusID "PCI:1:0:0" EndSection Section "Screen" Identifier "nvidia" Device "nvidia" Option "AllowEmptyInitialConfiguration" "Yes" EndSection Section "Device" Identifier "intel" Driver "modesetting" Option "AccelMethod" "none" EndSection Section "Screen" Identifier "intel" Device "intel" EndSection
