[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: RES: [shell-script] Colocar o ip em arquivo
From: |
Bash |
Subject: |
Re: RES: [shell-script] Colocar o ip em arquivo |
Date: |
Mon, 21 Jan 2002 12:46:12 -0200 |
Infelizmente não resolveu o problema, continuo com o mesmo erro.
Não seria algo dentro do script???
#!/bin/bash
ip_atual=`/sbin/ifconfig eth0 | /bin/grep inet | /usr/bin/cut -d : -f 2 |
/bin/awk '{print $1}'`
ip_antigo=`/usr/bin/cut -d " " -f 2 /etc/httpd/conf/ip.conf`
if [ "$ip_atual" != "$ip_antigo" ]
then
echo "NameVirtualHost $ip_atual" > /etc/httpd/conf/ip.conf
/etc/init.d/httpd restart
fi
At 12:24 21/01/2002 -0200, you wrote:
Se for csh ou tcsh, basta executar rehash
Se for bash, execute hash -r
Isso deve limpar a hash que o shell mantem para o caminho de arquivo
executaveis.
[]'s
Silvano
--
Bash
mailto:address@hidden
http://www.aboutlinux.com.br/
- RES: [shell-script] Colocar o ip em arquivo, Julio Cezar Neves - DISB.O, 2002/01/21
- Re: RES: [shell-script] Colocar o ip em arquivo, Bash, 2002/01/21
- Re: RES: [shell-script] Colocar o ip em arquivo, Fahrinha (Nautilus), 2002/01/21
- Re: RES: [shell-script] Colocar o ip em arquivo, Bash, 2002/01/21
- Re: RES: [shell-script] Colocar o ip em arquivo, Silvano B. Dias, 2002/01/21
- Re: RES: [shell-script] Colocar o ip em arquivo, Bash, 2002/01/21
- Re: RES: [shell-script] Colocar o ip em arquivo, Silvano B. Dias, 2002/01/21
- Re: RES: [shell-script] Colocar o ip em arquivo,
Bash <=
- Re: [shell-script] Colocar o ip em arquivo, Eliphas Levy Theodoro, 2002/01/21
- Message not available
- Re: [shell-script] Colocar o ip em arquivo, Bash, 2002/01/21