Re: [9fans] Backgrounding a task

2017-10-24 Thread Chris McGee
> Think about multiple processes owned by multiple users running on a > cpu server. Which processes should be allowed to join which > namespaces? > > Perhaps allowing only the hostowner to join namespaces for debugging > and administration purposes would be acceptable. Ah, right. What about

Re: [9fans] Backgrounding a task

2017-10-24 Thread Giacomo Tesio
Here it is: https://github.com/JehanneOS/jehanne/commit/320e6e6f35bfbc2e37dbd079c8d6a9124bd9ac6c The simple test attached confirms that it works as expected: https://github.com/JehanneOS/jehanne/blob/master/qa/kern/nsclone.c Now it's just matter of modifying the plumber to use this facility and

Re: [9fans] Backgrounding a task

2017-10-24 Thread Giacomo Tesio
2017-10-24 16:21 GMT+02:00 Alex Musolino : > Creating a child process is something that a process explicitly > controls and the RFNOTEG flag of rfork(2) allows a process to control > whether or not it shares its namespace with its children. Allowing > other, unrelated

Re: [9fans] Backgrounding a task

2017-10-24 Thread Alex Musolino
> The namespace join facility looks interesting. Do you have a patch > somewhere for it? I'll see what I can dig up though it wouldn't tbe erribly difficult to reimplement. You basically just need to modify the pgrp pointer of the proc, adjusting ref counts as required. >> Of course, a lot of

Re: [9fans] Backgrounding a task

2017-10-24 Thread Chris McGee
The namespace join facility looks interesting. Do you have a patch somewhere for it? > Of course, a lot of the isolation that per-process namespaces give you > is suddenly undone by the introduction of this facility. I'm not sure if the lack of isolation is any different than what can be done

Re: [9fans] Backgrounding a task

2017-10-23 Thread Alex Musolino
> So far, it looks like the closest equivalent is to draw a new window > and inherit the namespace of the original one by reading the namespace > from the proc. The problem with /proc/$pid/ns is entries that can't be "replayed". For example, the following command will not work: mount -b

Re: [9fans] Backgrounding a task

2017-10-23 Thread Yaroslav Kolomiiets
“window -m cmd” will run the command in the same namespace, forked, but in new window. “-m” is for “mount”, an alternative way of communication with the window system to /dev/wctl which is default. Yaroslav Kolomiiets 7 жовт. 2017 р. о 15:21 Chris McGee пише: Thanks for

Re: [9fans] Backgrounding a task

2017-10-07 Thread Chris McGee
Thanks for the tip! I'll give that a try. Chris > On Oct 7, 2017, at 12:04 AM, Skip Tavakkolian > wrote: > > Spitballing here: in the new window do something like > > cat /proc/123/ns | rc > > Or first massage the ns then generate an output for rc. > >> On Fri,

[9fans] Backgrounding a task

2017-10-06 Thread Chris McGee
Hi All, When I'm using Unix, there's a workflow that I use for long running commands that I'm hoping to find the equivalent in the Plan 9 way of doing things. I will occasionally run a command, realize that it will take a long time to complete. I don't want to kill it. I'll just Ctrl-Z and bg