DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

Roy
Roy

Posted on

quote in ssh bash -c

alt text

    cmd="find $volumePath/data -maxdepth 1 -type f -name 'GRA_*.log' -print0 | xargs -0 -n 100 rm -v"
    # εŒεΌ•ε·δΈ­bashε­ε‘½δ»€ιœ€θ¦δ½Ώη”¨ `\"` εΌ•η”¨οΌŒε¦εˆ™δΌšζŠ₯ι”™ "xargs argument line too long"
    ssh -p $sshPort $hostIP -- "bash -c \"$cmd\""
Enter fullscreen mode Exit fullscreen mode

https://serverfault.com/q/953087/576644

Top comments (0)

All DEV content is created by the community!

Hey, if you're landing here for the first time, you should know that this website is a global community of folks who blog about their experiences to help folks like you out.

Sign up now if you're curious. It's free!