User Tools

Site Tools


cluster:users

This is an old revision of the document!


Propagar usuarios de detritus hacia los nodos

Un nodo,

[root@detritus ~]# a=$(echo `grep cdalmasso /etc/passwd`); ssh brick01 "echo $a >> /etc/passwd"
[root@detritus ~]# ssh brick01 chmod +rw /etc/shadow
[root@detritus ~]# a=$(echo `grep cdalmasso /etc/shadow`); ssh brick01 "echo $a >> /etc/shadow"
[root@detritus ~]# ssh brick01 chmod -rw /etc/shadow
[root@detritus ~]# a=$(echo `grep cdalmasso /etc/group`); ssh brick01 "echo $a >> /etc/group"
[root@detritus ~]# ssh brick01 chmod +rw /etc/gshadow
[root@detritus ~]# a=$(echo `grep cdalmasso /etc/gshadow`); ssh brick01 "echo $a >> /etc/gshadow"
[root@detritus ~]# ssh brick01 chmod -rw /etc/gshadow

Todos

for x in $(seq 3);do 
a=$(echo `grep cdalmasso /etc/passwd`); ssh brick0${x} "echo '${a}' >> /etc/passwd";
ssh brick0{x} chmod +rw /etc/shadow;
a=$(echo `grep cdalmasso /etc/shadow`); ssh brick0{x} "echo '${a}' >> /etc/shadow";
ssh brick0{x} chmod -rw /etc/shadow;
a=$(echo `grep cdalmasso /etc/group`); ssh brick0{x} "echo '{$a}' >> /etc/group";
ssh brick0{x} chmod +rw /etc/gshadow;
a=$(echo `grep cdalmasso /etc/gshadow`); ssh brick0{x} "echo '${a}' >> /etc/gshadow";
ssh brick0{x} chmod -rw /etc/gshadow;
done

[root@detritus ~]# ssh brick01 chmod -rw /etc/gshadow

cluster/users.1567588564.txt.gz · Last modified: 2020/08/04 10:48 (external edit)