0
有沒有辦法將mongorestore輸出從命令行輸出到文件中?這是針對Linux/Unix的將mongorestore輸出放入文件
mongorestore --port $MONGO_PORT --db $database --archive=$BACKUP_NAME.archive >> log_file
創建一個空文件。
任何幫助都會被處理。
有沒有辦法將mongorestore輸出從命令行輸出到文件中?這是針對Linux/Unix的將mongorestore輸出放入文件
mongorestore --port $MONGO_PORT --db $database --archive=$BACKUP_NAME.archive >> log_file
創建一個空文件。
任何幫助都會被處理。
使用dir > a.txt 2>&1
或沿線解決我的問題。
試試這個https://stackoverflow.com/questions/1420965/redirect-windows-cmd-stdout-and-stderr-to-a-single-file – dnickless
是的,它工作正常,謝謝! – DoingItNow