Suppressing output from vagrant rsync-auto when in background

174 views
Skip to first unread message

Andrew Szczepanski

unread,
Aug 10, 2017, 12:11:00 PM8/10/17
to Vagrant
I'm trying to run `vagrant rsync-auto` in the background via the command `vagrant rsync-auto > /dev/null 2>&1 &`

However, the original session I ran the command from still receives messages from the process (or possible the subprocesses?) of `vagrant rsync-auto`.

eg:
"==> project: Watching: /Users/yourname/project"

I've also tried passing the `-q` flag like:

config.vm.synced_folder ".", "/home/ubuntu/project", type: "rsync", rsync__exclude: ".git/", rsync__args: ["-q", "--archive", "--delete", "-z"]

This actually gives more output than the default `--verbose` flag -- it now tells me which folders are excluded on each watcher update.

Does anyone know how to suppress this output?

Alvaro Miranda Aguilera

unread,
Aug 11, 2017, 6:24:06 AM8/11/17
to vagra...@googlegroups.com
what about

vagrant rsync-auto &>/dev/null

Virusvrij. www.avast.com

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/436605cf-ad29-4b9d-8e0c-078c5f7e0281%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

Andrew Szczepanski

unread,
Aug 16, 2017, 11:40:17 AM8/16/17
to Vagrant
I think that did it! To throw it in a background process I did:

(vagrant rsync-auto &>/dev/null) &

Thanks Alvaro!

On Friday, August 11, 2017 at 6:24:06 AM UTC-4, Alvaro Miranda Aguilera wrote:
what about

vagrant rsync-auto &>/dev/null

Virusvrij. www.avast.com
On Thu, Aug 10, 2017 at 6:11 PM, Andrew Szczepanski <andrewksz...@gmail.com> wrote:
I'm trying to run `vagrant rsync-auto` in the background via the command `vagrant rsync-auto > /dev/null 2>&1 &`

However, the original session I ran the command from still receives messages from the process (or possible the subprocesses?) of `vagrant rsync-auto`.

eg:
"==> project: Watching: /Users/yourname/project"

I've also tried passing the `-q` flag like:

config.vm.synced_folder ".", "/home/ubuntu/project", type: "rsync", rsync__exclude: ".git/", rsync__args: ["-q", "--archive", "--delete", "-z"]

This actually gives more output than the default `--verbose` flag -- it now tells me which folders are excluded on each watcher update.

Does anyone know how to suppress this output?

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+...@googlegroups.com.



--
Alvaro

Alvaro Miranda Aguilera

unread,
Aug 16, 2017, 12:05:17 PM8/16/17
to vagra...@googlegroups.com
to explain what happen on your command:

this:

> /dev/null 2>&1 &

says:

send std output to null
send std err to stdoutput
send job to background

i think order matters

2>&1 > /dev/null  &

should have done the trick,  but &>/dev/null send alls to null

Alvaro


To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/7233dd17-e0c9-4e15-a24f-9474cf2e84ce%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Alvaro

Reply all
Reply to author
Forward
0 new messages