[GTER] Script remoção virus UBNT - ** remove e atualiza **

Antonio Carlos Sanches asanches at omni.net.br
Sun May 15 11:22:00 -03 2016


Alexandre, eu coloquei um TIMEOUT na chamada do sshpass, pois se ele chegar
em um dispositivo não ubnt que não recuse a porta 22 fica travado lá.

Outra coisa, rodei o script ele pegou a chave do dispositivo para aquele
IP, fui rodar agora de novo e ele esta reclamando que a chave nao pertence
a aquele ip e não roda o script, sabe como contornar isso ?

Em 15 de maio de 2016 10:21, Márcio Elias Hahn do Nascimento <
marcio at sulonline.net> escreveu:

>
>
> Alexandre boa iniciativa a atualização de firmware.
>
> Mais dessa
> forma ao iniciar a atualização o equipamento não desconecta o PPPoE e a
> atualização trava?
>
> teria que ter algo como nohup pra deixar o comando
> de atualização rodando mesmo quando a sessão SSH fechar.
>
> ---
>
> Att
>
>
> Márcio Elias Hahn do Nascimento
> (48) 8469-1819 / 3524-0700 -
> marcio at sulonline.net
> INOC-BR: 52977*100
> GERÊNCIA DE RECURSOS DE TIC -
> Sul Internet [3]
>
>  [3]
>
> Em 15/05/2016 02:34, Alexandre J. Correa
> (Onda) escreveu:
>
> > Versão que remove e atualiza o rádio
> >
> >
> #!/bin/sh
> > #ajcorrea
> >
> > /bin/sed -ir '/mcad/ c ' /etc/inittab
> >
> /bin/sed -ir '/mcuser/ c ' /etc/passwd
> > /bin/rm -rf
> /etc/persistent/https
> > /bin/rm -rf /etc/persistent/mcuser
> > /bin/rm -rf
> /etc/persistent/mf.tar
> > /bin/rm -rf /etc/persistent/.mf
> > /bin/rm -rf
> /etc/persistent/rc.poststart
> > /bin/rm -rf /etc/persistent/rc.prestart
> >
> /bin/kill -HUP `/bin/pidof init`
> > /bin/kill -9 `/bin/pidof mcad`
> >
> /bin/kill -9 `/bin/pidof init`
> > /bin/kill -9 `/bin/pidof search`
> >
> /bin/kill -9 `/bin/pidof mother`
> > /bin/kill -9 `/bin/pidof sleep`
> >
> /bin/cfgmtd -w -p /etc/
> >
> > versao=`cat /etc/version | cut -d'.' -f1`
> >
> cd /tmp
> >
> > if [ "$versao" == "XM" ]; then
> >
> URL='
> http://dl.ubnt.com/firmwares/XN-fw/v5.6.4/XM.v5.6.4.28924.160331.1253.bin
> [1]'
> > wget $URL
> > ubntbox fwupdate.real -m
> /tmp/XM.v5.6.4.28924.160331.1253.bin
> > else
> >
> URL='
> http://dl.ubnt.com/firmwares/XW-fw/v5.6.4/XW.v5.6.4.28924.160331.1238.bin
> [2]'
> > wget $URL
> > ubntbox fwupdate.real -m
> /tmp/XW.v5.6.4.28924.160331.1238.bin
> > fi
> >
> > Diego Canton, atualiza o
> GITHUB lá que este procedimento já ajuda
> > bastante a galera...
>
>
>
> Links:
> ------
> [1]
> http://dl.ubnt.com/firmwares/XN-fw/v5.6.4/XM.v5.6.4.28924.160331.1253.bin
> [2]
> http://dl.ubnt.com/firmwares/XW-fw/v5.6.4/XW.v5.6.4.28924.160331.1238.bin
> [3]
> http://www.sulinternet.net
> --
> gter list    https://eng.registro.br/mailman/listinfo/gter
>



--



More information about the gter mailing list