amt has asked for the wisdom of the Perl Monks concerning the following question:
This is the string that I send as $reloadcmd.####### Begin Dumb Propagate Function ####### foreach $addr (keys %FR_servers) { if( system("sudo /usr/bin/scp -Bpq $config_file $addr: +/usr/local/etc/raddb/") == 0 ){ $FR_servers{$addr} = 1; # mar +k for user feedback } else { $FR_servers{$addr} = 0;} if( system("sudo /usr/bin/scp -Bpq $users_file $addr:/ +usr/local/etc/raddb/") == 0){ $FR_servers{$addr} = 1; } else { $FR_servers{$addr} = 0;} system("sudo ssh $addr $reloadcmd"); # reload freeradi +us remotely } ####### Finish Dumb Propagate Function #######
The file /tmp/reload_output on the local file system has output, however, the remote system doesn't have the redirected output.# command for reloading FreeRadius configuration # touching the file works on both local and remote filesystems my $reloadcmd = "/usr/local/sbin/rc.radiusd reload > /tmp/reload_ouput +"; #"/bin/touch /tmp/test_reload_config";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: FR Reload Issues
by samtregar (Abbot) on Nov 03, 2004 at 17:52 UTC | |
by amt (Monk) on Nov 03, 2004 at 18:14 UTC | |
by samtregar (Abbot) on Nov 03, 2004 at 19:14 UTC | |
by amt (Monk) on Nov 04, 2004 at 14:48 UTC |