This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
| { | |
| "installed_packages": | |
| [ | |
| "Alignment", | |
| "ApacheConf.tmLanguage", | |
| "BracketHighlighter", | |
| "Dayle Rees Color Schemes", | |
| "HTML5", | |
| "jQuery", | |
| "jQuery Snippets pack", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -- Display all the database names on the instance | |
| EXEC sp_databases | |
| -- Display database size | |
| USE database_Name; | |
| GO EXEC sp_spaceused N'table_Name'; | |
| GO | |
| -- Put the db in read-only mode | |
| USE master EXEC sp_dboption 'Nom_Database', 'read only', 'TRUE' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -- The .sql file will contain drop table, create table and insert command for all the tables in the specified database. | |
| -- if necessary, install mysqldump | |
| sudo apt-get install mysqldump | |
| -- backup: | |
| mysqldump -u root -p[root_password] [database_name] > dumpfilename.sql | |
| -- restore: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| :: Commande DOS pour récupérer les différents moniteurs de performance sur une machine Windows : | |
| typeperf -qx>>perfcounter.txt | |
| :: Commande pour afficher les serveurs qui hébergent LDAP dans le domaine | |
| :: Peut être exécuté sans le "domaine name" et retourne tout les domaines disponibles | |
| nslookup | |
| > set types=all | |
| > _ldap._tcp.<your domain name> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| dig +short @resolver1.opendns.com myip.opendns.com |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Display tcp connections on the machine and their states. | |
| netstat -an | awk '/tcp/ {print $6}' | sort | uniq -c |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| openssl dgst -sha256 /path/to/file |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # To remember this simple trick, RSYNC cmd | |
| # | |
| # -a option will use recursive mode, preserve any symbolic links, preserves file and directory permissions, | |
| # preserves the timestamp, and preserve the owner and group. | |
| # -v for verbose mode or info=progress2 for rsync 3.0+ | |
| rsync -av --exclude ".DS_Store" --progress /Volumes/Source/ /Volumes/TargetBackup/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| afinfo /path_to/filename.format | grep "bit rate" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # commande : xattr | |
| # affiche les attributs étendus du fichier | |
| xattr /path_to/filename | |
| # supprimer un attribut | |
| xattr -d com.apple.quarantine /path_to/filename | |
| # supprimer tous les attributs du fichier | |
| xattr -c /path_to/filename |
OlderNewer