課程
/運維&測試
/Linux
/Shell典型應用之系統信息及運行狀態獲取
誰能告訴我是什么意思呀?
2016-11-14
源自:Shell典型應用之系統信息及運行狀態獲取 1-2
正在回答
#!/bin/dash
/*a simple shell*/
/* use command 'leave' to exit*/
?
#include <unistd.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <fcntl.h>
#define BUFFERSIZE 80
extern char *get_current_dir_name(void);
extern char *getenv(const char *name);
extern pid_t waitpid(pid_t pid, int *status, int options);
char buffer[BUFFERSIZE+1];
如果要改,還是要看你的腳本里面的具體內容來改,順便,修改權限的命令是:chmod 權限值 文件名;
ls437088 提問者
第2和第3行的代碼權限不夠,第13行的代碼語法錯誤;(你可以用set nu來查看行號)
舉報
Linux系統常用信息及運行狀態監控,能夠使用shell腳本進行分析
3 回答老師您好,/bin/sh和/bin/sh在執行腳本的時候有什么不同啊?
2 回答if [[ ! ${execshell} =~ ^[0-9]+ ]];中的“=~ ” 是什么意思?
1 回答第一個運行的腳本在mac下面就涼了,語法錯誤。。。
2 回答grep -E “\<nameserver[ ]+”中的 “\<”是什么意思
2 回答linux shell找tomcat下的目錄
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號-11 京公網安備11010802030151號
購課補貼聯系客服咨詢優惠詳情
慕課網APP您的移動學習伙伴
掃描二維碼關注慕課網微信公眾號
2016-11-14
#!/bin/dash
/*a simple shell*/
/* use command 'leave' to exit*/
?
#include <unistd.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <fcntl.h>
?
#define BUFFERSIZE 80
?
extern char *get_current_dir_name(void);
extern char *getenv(const char *name);
extern pid_t waitpid(pid_t pid, int *status, int options);
?
char buffer[BUFFERSIZE+1];
2016-11-14
如果要改,還是要看你的腳本里面的具體內容來改,順便,修改權限的命令是:chmod 權限值 文件名;
2016-11-14
第2和第3行的代碼權限不夠,第13行的代碼語法錯誤;(你可以用set nu來查看行號)