我有開機運行在領新啓動腳本:運行一圈請求
的/ etc /初始化/ selfconfig
#! /bin/sh
# /etc/init.d/selfconfig
USER=root
HOME=/root
export USER HOME
/usr/bin/perl /boot/coder_settings/saconfig.pl
exit 0
這個腳本運行的Perl腳本
/boot/coder_settings/saconfig.pl
#! /usr/bin/perl
lwp-request -m GET http://192.168.1.16:3000/hostname > /boot/coder_settings/hostname.txt
但我得到這個錯誤:
Search pattern not terminated at /boot/coder_settings/saconfig.pl line 3.
我在做什麼錯?
嘗試:LWP請求-m GET 'http://192.168.1.16:3000/hostname'> /boot/coder_settings/hostname.txt – michael501 2014-10-30 22:52:37