Catégorie : Gestion de serveur
-
Fichier mysql-slow.log
Dans : /etc/my.cnf log-slow-queries = /var/log/mysql-slow.log long_query_time = 5 log-long-format #log-queries-not-using-indexes log-warnings=2 Dans : /var/log/ touch mysql-slow.log chmod 660 mysql-slow.log chown mysql:mysql mysql-slow.log service mysql restart
-
Installer tuning-primer et mysqltuner
tuning-primer : wget http://day32.com/MySQL/tuning-primer.sh chmod 755 tuning-primer.sh ./tuning-primer.sh mysqltuner : wget http://mysqltuner.com/mysqltuner.pl chmod +x mysqltuner.pl ./mysqltuner.pl ou perl mysqltuner.pl
-
pam_loginuid(crond:session): set_loginuid failed opening loginuid
Quand on a des centaines de lignes de ce genre dans les fichiers de log (cause kernel modifié ?) : pam_loginuid(crond:session): set_loginuid failed opening loginuid Faire : cd /etc/pam.d =>editer le fichier crond et commenter la ligne : #session required pam_loginuid.so
-
Move and copy files
The mv command syntax looks like this: mv configuration.php-dist configuration.php By issuing the above command we will move (rename) the file configuration.php-dist to configuration.php. You can also use mv to move a whole directory and its content: mv includes/* ./ This will move all files (and folders) in the includes/ directory to the current working…
-
VI
http://amath.colorado.edu/computing/unix/vi/ Using the VI editor (the very basics) The VI editor is a screen-based text editor available on all Unix computers (and available for all other kinds of computers, sometimes as « vim » rather than « vi »). Given that it takes some effort, why bother to learn VI? Because sometimes it’s the only available editor when you…
-
Archiver – gzip et zip
http://www.centos.org/docs/2/rhl-gsg-en-7.2/s1-zip-tar.html File Compression and Archiving with Gzip, Zip, and Tar Compressing with Gzip and Zip Compressed files use less disk space and download faster than large, uncompressed files. You can compress Linux files with the open-source compression tool Gzip or with Zip, which is recognized by most operating systems. By convention, compressed files are given…
-
Savoir si le serveur est en 32 ou 64 bits
Pour savoir si le système est en 32/64 bits : uname -a Pour avoir des infos sur le microprocesseur : cat /proc/cpuinfo
-
Voir ports ouverts et autres informations
Sous Ubuntu : sudo netstat -ape46
-
Start stop RED5
Login to ssh and enter the following commands. #cd /usr/local/red5 to stop red5 : ./red5-shutdown.sh to start red5: ./red5.sh & When you see this line: 2009-09-27 23:26:32,365 [main] INFO org.red5.server.Standalone – Startup done i n: 5464 ms (it will be easy because the lines will stop running at this point) Wait 15 seconds Then you…
-
N’autoriser qu’un seul utilisateur à se connecter en SSH
Dans /etc/ssh/sshd_config, ajouter : AllowUsers NomDuUser