mirror of
https://github.com/ossrs/srs.git
synced 2025-02-12 11:21:52 +00:00
Refine script and startup logs. 3.0.148
This commit is contained in:
parent
aac170b75e
commit
8445d5543b
4 changed files with 10 additions and 11 deletions
|
@ -145,6 +145,7 @@ For previous versions, please read:
|
|||
|
||||
## V3 changes
|
||||
|
||||
* v3.0, 2020-10-24, Refine script and startup logs. 3.0.148
|
||||
* v3.0, 2020-10-23, Allow FFmpeg if exists at /usr/local/bin/ffmpeg. 3.0.147
|
||||
* v3.0, 2020-10-23, Refine build script, use libssl in docker. 3.0.146
|
||||
* v3.0, 2020-10-14, Fix [#1987][bug #1987], Fix Kbps resample bug. 3.0.145
|
||||
|
|
|
@ -51,10 +51,10 @@ load_process_info() {
|
|||
pid_file=`(cd ${ROOT}; cd $pid_dir; pwd)`/`basename $pid_file`
|
||||
|
||||
srs_pid=`cat $pid_file 2>/dev/null`
|
||||
ret=$?; if [[ 0 -ne $ret ]]; then error_msg="file $pid_file does not exists"; return 1; fi
|
||||
ret=$?; if [[ 0 -ne $ret ]]; then error_msg="No pid file $pid_file"; return 1; fi
|
||||
|
||||
ps -p ${srs_pid} >/dev/null 2>/dev/null
|
||||
ret=$?; if [[ 0 -ne $ret ]]; then error_msg="process $srs_pid does not exists"; return 2; fi
|
||||
ret=$?; if [[ 0 -ne $ret ]]; then error_msg="Process $srs_pid does not exists"; return 2; fi
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -142,9 +142,9 @@ stop() {
|
|||
# @return 0 if srs is running; otherwise, 1 for stopped.
|
||||
status() {
|
||||
load_process_info
|
||||
ret=$?; if [[ 0 -eq $ret ]]; then echo "SRS(pid ${srs_pid}) is running."; return 0; fi
|
||||
ret=$?; if [[ 0 -eq $ret ]]; then ok_msg "SRS(pid ${srs_pid}) is running."; return 0; fi
|
||||
|
||||
echo "SRS is stopped, $error_msg"
|
||||
failed_msg "Error: $error_msg"
|
||||
return 1
|
||||
}
|
||||
|
||||
|
|
|
@ -1940,9 +1940,8 @@ srs_error_t SrsConfig::parse_options(int argc, char** argv)
|
|||
return srs_error_new(ERROR_SYSTEM_CONFIG_INVALID, "no log file");
|
||||
}
|
||||
if (get_log_tank_file()) {
|
||||
srs_trace("write log to file %s", log_filename.c_str());
|
||||
srs_trace("you can: tailf %s", log_filename.c_str());
|
||||
srs_trace("@see: %s", SRS_WIKI_URL_LOG);
|
||||
srs_trace("you can check log by: tail -f %s (@see %s)", log_filename.c_str(), SRS_WIKI_URL_LOG);
|
||||
srs_trace("please check SRS by: ./etc/init.d/srs status");
|
||||
} else {
|
||||
srs_trace("write log to console");
|
||||
}
|
||||
|
@ -3618,9 +3617,8 @@ srs_error_t SrsConfig::check_normal_config()
|
|||
return srs_error_new(ERROR_SYSTEM_CONFIG_INVALID, "log file is empty");
|
||||
}
|
||||
if (get_log_tank_file()) {
|
||||
srs_trace("write log to file %s", log_filename.c_str());
|
||||
srs_trace("you can: tailf %s", log_filename.c_str());
|
||||
srs_trace("@see: %s", SRS_WIKI_URL_LOG);
|
||||
srs_trace("you can check log by: tail -f %s (@see %s)", log_filename.c_str(), SRS_WIKI_URL_LOG);
|
||||
srs_trace("please check SRS by: ./etc/init.d/srs status");
|
||||
} else {
|
||||
srs_trace("write log to console");
|
||||
}
|
||||
|
|
|
@ -24,6 +24,6 @@
|
|||
#ifndef SRS_CORE_VERSION3_HPP
|
||||
#define SRS_CORE_VERSION3_HPP
|
||||
|
||||
#define SRS_VERSION3_REVISION 147
|
||||
#define SRS_VERSION3_REVISION 148
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue