If like me you do not have a fixed IP addres, you may have to update a DNS record.
And if you use a VPN, you want to update the DNS record with your real IP address.
Here is a bootscript to do that in Python.
Continue reading »If like me you do not have a fixed IP addres, you may have to update a DNS record.
And if you use a VPN, you want to update the DNS record with your real IP address.
Here is a bootscript to do that in Python.
Continue reading »The scality’s RING product is a distributed storage solution, which manages different replication and erasure coding security. – https://www.scality.com/
A RING keyspace is a circle starting at 00, ending at FF.
in reality, the numbers are not just 2 character long but 40 characters.
A keyspace is composed of node keyranges.
A keyrange is a space between a key on the keyspace, and the predecessor key.
On m’a demandé comment copier sans écraser la destination si elle existe.
l’environnement est restreint, pas de rsync et doit tenir dans une ligne.
pas le temps de tester si le fichier existe, ce doit être rapide.
la solution est facile:
# yes |sed 's/y/n/' | cp -i source destination
Here is my custom PS1 for GIT.
You can see if you are in a GIT tree, the current branch and the status of the branch (the + or the – before the branch)
The special command to obtain this kind of prompt is
Works on Bash only
cidr2dec() { cidr=$1 totalmask= ; bits= for ((i=$cidr; $i>0; i--)); do bits="${bits}1" ; done for ((i=$((32 - $cidr)); $i>0; i--)); do bits="${bits}0" ; done for i in 1 9 17 25; do bitmask=$(echo $bits |cut -c${i}-$(($i + 7))) totalmask=${totalmask}$(echo 'obase=10; ibase=2;' $bitmask |bc). done echo ${totalmask%%.} }
$ for i in 16 24 26 27 32 ; do cidr2dec $i ; done 255.255.0.0 255.255.255.0 255.255.255.192 255.255.255.224 255.255.255.255