9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* Re: [9fans] Install from CD fails
@ 2006-04-20  1:41 erik quanstrom
  2006-04-20  6:17 ` Charles Forsyth
  0 siblings, 1 reply; 131+ messages in thread
From: erik quanstrom @ 2006-04-20  1:41 UTC (permalink / raw)
  To: 9fans

On Wed Apr 19 20:05:43 CDT 2006, rog@vitanuova.com wrote:
> i had es in mind when i wrote the inferno shell (vita nuova's, not the original tiny shell).

the inferno shell is quite nice.  good job.

> i thought then that some of the es concepts were nice, but the whole complete functional language
> thing was overkill and didn't get one very far (why make it possible to redefine
> core shell concepts such as the pipe? - it just confuses everyone if you make use of this.)

for starters, it makes a nice paper.  ;-)   also it was used for the es debugger.  i never found it confusing
(due to lexical bindings) but never made use of it, either.

> for instance:
> > 	; if {condition1} {body1} {condition2} {body2}
>
> is not implemented by the core inferno shell, but by an externally loaded
> module (std).
>

pretty nice!

>
> the main problem is that a shell of this style
> has no concept of storage of any item but a string (ok, a list of strings), so it is not
> possible to manipulate other data items directly. [...]
>
> i don't think it's possible to address these problems without
> breaking the simplicity of the whole thing; the moment you
> introduce lexical binding, differently typed variables, etc,
> a whole raft of other issues starts to drift into view.
> another kind of language might begin to help, but that's another
> story.

i think you're right.  i wrote a shell in college that was similar to rc, but
lists were allowed to contain lists.  even this proved to be unworkable, as
"for(i in *.c *.h) echo $i" would print
	a.c b.c
	x.h y.h z.h
and not what was expected.

>
> just having shell blocks as values is a big win, in my book.
> i don't think it would be hard to do this in rc.

i don't think it would be hard, but it would break td's basic design of compiling
everything at input time.  one way to thinking of es' rewriting is that it is
like rc's bytecode exposed.  i don't think it really hangs together though.  is this
	a | b
or this
	%pipe {a} 0 1 {b}
es code?

also, what does a traditional rc function do with a shell block?

>
> > a trivial grep module could make
> >	; grep {^fn} *.[ch]
> > acceptable syntax.
>
> i'm sorry, i don't see why this is preferable to the original.
> it has the same number of characters.

it doesn't!  i didn't intend to imply that it did.  it was a trivial example.

- erik



^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-25  2:16 erik quanstrom
  0 siblings, 0 replies; 131+ messages in thread
From: erik quanstrom @ 2006-04-25  2:16 UTC (permalink / raw)
  To: 9fans

the fact that the unix environment has gotten out of control had
made things that should be simple (like man), quite difficult.

unfortunately, that's a different problem.  my main issue with
tcl is this:

	; man -k tcl|wc -l
	7191

that's just a wee bit out of control, no?

- erik

On Mon Apr 24 21:03:56 CDT 2006, rvs@sun.com wrote:
> > i'm probablly on my own in this, but tcl is just strange, and its
> > linux implementation never ceases to annoy, and it's way too big.
> > since when is \t anything other than whitespace?  (python, unfortunately, did
> > the same thing).  when i try to "man -k" on a system with tcl,
> > i get a hundred of useless tcl/tk commands.
>
>   Yeap. In fact, I still don't understand why $ man foo/bar doesn't do
>   what I perceive to be the right thing...
>
> Thanks,
> Roman.



^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-21 15:49 erik quanstrom
  0 siblings, 0 replies; 131+ messages in thread
From: erik quanstrom @ 2006-04-21 15:49 UTC (permalink / raw)
  To: 9fans

that mkfile is way too big.  how are we going to fit it on these new 750GB drives
(http://hardware.slashdot.org/hardware/06/04/20/2358213.shtml)?

- erik

On Fri Apr 21 10:48:02 CDT 2006, 9nut@9netics.com wrote:
> > skip had a pre-release a year ago.
>
> cpu% ls -l /usr/brucee/inferno/appl
> d-rwxrwxr-x M 30904 brucee brucee   0 May 14  2005 /usr/brucee/inferno/appl/cmd
> d-rwxrwxr-x M 30904 brucee brucee   0 May 14  2005 /usr/brucee/inferno/appl/dispatch
> d-rwxrwxr-x M 30904 brucee brucee   0 May 14  2005 /usr/brucee/inferno/appl/funnel
> d-rwxrwxr-x M 30904 brucee brucee   0 May 14  2005 /usr/brucee/inferno/appl/journal
> d-rwxrwxr-x M 30904 brucee brucee   0 May 14  2005 /usr/brucee/inferno/appl/legacy
> d-rwxrwxr-x M 30904 brucee brucee   0 May 14  2005 /usr/brucee/inferno/appl/lib
> d-rwxrwxr-x M 30904 brucee brucee   0 May 14  2005 /usr/brucee/inferno/appl/mash
> --rw-rw-r-- M 30904 brucee brucee 106 May 14  2005 /usr/brucee/inferno/appl/mkfile
> d-rwxrwxr-x M 30904 brucee brucee   0 May 14  2005 /usr/brucee/inferno/appl/stuff
> d-rwxrwxr-x M 30904 brucee brucee   0 May 14  2005 /usr/brucee/inferno/appl/xml
> cpu%
>


^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-20 10:36 erik quanstrom
  0 siblings, 0 replies; 131+ messages in thread
From: erik quanstrom @ 2006-04-20 10:36 UTC (permalink / raw)
  To: 9fans

perhaps you did things more elegantly than i.  when i wrote my shell back when,
getting this kind of stuff to work took quite a bit of effort

	fn f{
		if($1)
			$2
	}

	f {~ 1 1} {echo fu}

- erik

On Thu Apr 20 01:18:42 CDT 2006, forsyth@terzarima.net wrote:
> > also, what does a traditional rc function do with a shell block?
>
> invoke it.  i did something in a variant of 7th edition shell that was roughly similar.
> i remember!  i converted {block} as arguments into shell functions exported to the environment
> (having added 8th edition style shell functions and exported shell functions to 7th edition shell).
> the shell replaced the {} block by the function name before calling the command.
> thus allowing
> 	find usual-find-syntax -exec {mv $file /n/distant/$file}
> where the modified find put the current name in the environment $file, removing the need for {} and the \;
> find saw ... -exec my-exported-fn-name, and execvp would invoke /bin/sh -c my-exported-fn-name.
> 	time {a | pipe | line}; nohup {another; sequence; of; commands}
> this relied on the environment not being shared, of course
> and having the source to 7th edition.
>


^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-20 10:30 erik quanstrom
  2006-04-20 13:50 ` David Leimbach
                   ` (2 more replies)
  0 siblings, 3 replies; 131+ messages in thread
From: erik quanstrom @ 2006-04-20 10:30 UTC (permalink / raw)
  To: 9fans

On Wed Apr 19 23:03:19 CDT 2006, rvs@sun.com wrote:
>   I think Tcl has struck a nice balance here -- everything is a command
>   taking a number of arguments. Or are you talking about a different
>   sort of interface ?

i mean the dynamic module interface.

>
> > 2. what hooks are provided by the shell.  the "es" shell provided a hook
> > for darn near every language construct there was.  for example, it was possible
> > to redefine globbing, piping, the if statement, etc.
>
>   That is a bit too much, in my oppinion. I think what the 'core' shell
>   is supposed to do is provide a nice glue for the rest of the dynamic
>   functionality. Sort of like file system is a universal glue for every
>   other application running on the system. I would say that this is the
>   most challenging aspect of designing my dream 'shell' -- the glue is
>   supposed to be easy enough for me to understand, yet powerful enough
>   to express simple things in simple terms. Tcl comes pretty close
>   to being that glue.

give it a try:
	ftp://ftp.sys.toronto.edu/pub/es/es-0.9-beta1.tar.gz
it is very interesting, if not completely successful.

i'm probablly on my own in this, but tcl is just strange, and its
linux implementation never ceases to annoy, and it's way too big.
since when is \t anything other than whitespace?  (python, unfortunately, did
the same thing).  when i try to "man -k" on a system with tcl,
i get a hundred of useless tcl/tk commands.

- erik



^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-20  9:57 erik quanstrom
  2006-04-20 11:00 ` R
  0 siblings, 1 reply; 131+ messages in thread
From: erik quanstrom @ 2006-04-20  9:57 UTC (permalink / raw)
  To: 9fans

es scans the bit inside the {} as a string and does not parse it until it is used.

- erik

On Thu Apr 20 01:09:02 CDT 2006, forsyth@terzarima.net wrote:
> >> es did this: anything passed to a function inside curly braces was passed verbatim.
> >
> > that was the main bit of es that i stole for the inferno shell. it works well,
> > and combined with dynamically loaded shell modules, makes many nice things quite
> > easy.
>
> i thought that in the inferno sh the bit inside the {} was parsed, and later converted
> back to a string if passed to a command (uniform treatment of {} as in `{}, and you
> discover your syntax errors in good time).  i don't remember what es did.
>


^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-20  1:45 erik quanstrom
  2006-04-20  3:03 ` Michael Baldwin
  0 siblings, 1 reply; 131+ messages in thread
From: erik quanstrom @ 2006-04-20  1:45 UTC (permalink / raw)
  To: 9fans

i believe it's inferno's answer to mk.

http://www.vitanuova.com/inferno/man/1/mash.html

On Wed Apr 19 20:08:23 CDT 2006, rvs@sun.com wrote:
> On Thu, Apr 20, 2006 at 05:42:15AM +1000, Bruce Ellis wrote:
> > that is how mash works ... you augment it's command set by loading
> > modules (for example "make").
>
>   what's mash ?
>
> Thanks,
> Roman.
>
> P.S. And yes, I've tried google ;-)


^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-19  8:19 YAMANASHI Takeshi
  0 siblings, 0 replies; 131+ messages in thread
From: YAMANASHI Takeshi @ 2006-04-19  8:19 UTC (permalink / raw)
  To: 9fans

> the boundary is a bit blurred on inferno,
> because the explicitly module loading there
> is most commonly used to load what on other
> systems would be libraries.

I also have an feeling that the boundary between
library call and exec'ing is blurred on inferno.
--



^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-19  3:27 Mike Haertel
  0 siblings, 0 replies; 131+ messages in thread
From: Mike Haertel @ 2006-04-19  3:27 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

>I once knew
>someone who thought that a context switch was less expensive using
>shared libraries than without.

That could actually be true in some situations, for the following reason:
if program A and B have small unshared amounts of memory, but are sharing
many megabytes of libraries, potentially there are far fewer cache misses
after a context switches than there would be in the case that A and B
were each statically linked with their own copies of the many megabytes
of libraries.

However, some of this benefit is eaten by TLB misses: dynamically
linked programs tend to have much more total active virtual address
space than the corresponding statically linked programs that link only
the code they need.  And TLBs usually get flushed by context switches.
So some of the savings gained by not thrashing things in and out of the
cache is lost to thrashing things in and out of the TLBs.  TLB misses
are usually more expensive than cache misses, since a single TLB miss
can spawn many cache misses.


^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-19  3:04 erik quanstrom
  0 siblings, 0 replies; 131+ messages in thread
From: erik quanstrom @ 2006-04-19  3:04 UTC (permalink / raw)
  To: 9fans

i think this is a case of robust agreement;
russ is just much better explaining himself than i.

- erik

On Tue Apr 18 21:53:00 CDT 2006, rsc@swtch.com wrote:
> > dynamic linking allows one to extend a program without inventing a metalanguage.
> > i believe there is a paper on how inferno's shell uses this to nice effect.
>
> shared libraries != dynamic loading of modules.
> both require a dynamic linking implementation
> but they are not at all the same.
>
> shared libraries are just a bad replacement
> for static libraries.  they're used implicitly without
> a program having to ask for anything, and there
> is never an appropriate situation in which
> to use them.
>
> dynamic loading of modules can be a very
> powerful method of extension.  i have been
> meaning for a long time to convert snoopy to
> make the protocol parsers dynamically loaded
> instead of having one huge binary.  the inferno
> shell is another good example.
>
> the boundary is a bit blurred on inferno,
> because the explicitly module loading there
> is most commonly used to load what on other
> systems would be libraries.  but the result,
> at least as implemented, has a very different
> feel from the shared library hell on unix
> and windows.
>
> russ
>


^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-19  2:47 erik quanstrom
  0 siblings, 0 replies; 131+ messages in thread
From: erik quanstrom @ 2006-04-19  2:47 UTC (permalink / raw)
  To: 9fans

i think the right solution to this problem is to run a password server at
a known "address" that is independent of namespace.  only the c library needs
to know about this. (there are other unix traditions than can be kept in a world
were normal users can mount and bind this way.)


- erik

On Tue Apr 18 14:53:50 CDT 2006, leimy2k@gmail.com wrote:
> On 4/18/06, Russ Cox <rsc@swtch.com> wrote:
> > > A masking bind over /etc/passwd could be disasterous
> > > on Unix and I don't think anyone has really solved this problem yet
> >
> > this is trivial to solve.  setuid binaries should run
> > in the default system name space instead of inheriting
> > the one in use where they are started.
> >
> > russ
>
> Hmmm, anyone spoken to Al Viro about this?


^ permalink raw reply	[flat|nested] 131+ messages in thread
* Re: [9fans] Install from CD fails
@ 2006-04-19  2:35 erik quanstrom
  2006-04-19  3:53 ` Russ Cox
  2006-04-19 19:34 ` Roman Shaposhnick
  0 siblings, 2 replies; 131+ messages in thread
From: erik quanstrom @ 2006-04-19  2:35 UTC (permalink / raw)
  To: 9fans

i think there is a #3 here.  extension.

dynamic linking allows one to extend a program without inventing a metalanguage.
i believe there is a paper on how inferno's shell uses this to nice effect.

- erik

On Tue Apr 18 16:56:40 CDT 2006, leimy2k@gmail.com wrote:
> >   And you would have to go through all of the aforementioned troubles
> >   to achieve exactly what ? What is it, that shared libraries are good
> >   at ?
>
> #1 Maintenance - If you have 50 programs that depend on one library
> and you have a fix for the library how many things do you want to
> "remember to build"?  (though people are throwing up straw man
> arguments for this too.  I suspect the worst case scenario is not
> always the common case though.)
>
> #2 Supposed physical memory savings - libSystem on Mac OS X only
> exists in memory 1 time for all the programs that use it... sorta.
> Read Only pages are shared, writable pages are COW and yes, this adds
> a good deal of complexity to the VM of the OS to have this.
>


^ permalink raw reply	[flat|nested] 131+ messages in thread
* [9fans] Install from CD fails
@ 2006-04-17 22:07 Bakul Shah
  2006-04-18  0:01 ` Russ Cox
  0 siblings, 1 reply; 131+ messages in thread
From: Bakul Shah @ 2006-04-17 22:07 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Installing from the latest CD (fetched today from tip9ug.jp)
fails in the copydist step with the following message

--------------------------------------
usage: replica/pull [-nv] [-c name] [-s name] replica-name [paths]

--------------------------------------

I took a quick look at /sys/lib/dist/pc/inst/copydist and
think the culprit is this line:

	 replica/pull -c /rc/bin/inst/replcfg

Doesn't it need an extra argument now?  I doubt it matters
but this was an install in a qemu VM.  Thanks!


^ permalink raw reply	[flat|nested] 131+ messages in thread

end of thread, other threads:[~2006-04-25  2:16 UTC | newest]

Thread overview: 131+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-04-20  1:41 [9fans] Install from CD fails erik quanstrom
2006-04-20  6:17 ` Charles Forsyth
2006-04-20  6:35   ` [9fans] [OT] URI Charles Forsyth
2006-04-20  6:53     ` geoff
2006-04-20 15:01       ` Brantley Coile
2006-04-20 15:32         ` Paul Lalonde
2006-04-20 15:49           ` Brantley Coile
2006-04-20 16:04             ` Paul Lalonde
2006-04-20 16:47               ` Jack Johnson
2006-04-21  9:22                 ` Moritz Kiese
2006-04-21 14:47                   ` Brantley Coile
2006-04-21  4:54             ` quanstro
  -- strict thread matches above, loose matches on Subject: below --
2006-04-25  2:16 [9fans] Install from CD fails erik quanstrom
2006-04-21 15:49 erik quanstrom
2006-04-20 10:36 erik quanstrom
2006-04-20 10:30 erik quanstrom
2006-04-20 13:50 ` David Leimbach
2006-04-20 17:55 ` Skip Tavakkolian
2006-04-25  2:02 ` Roman Shaposhnick
2006-04-20  9:57 erik quanstrom
2006-04-20 11:00 ` R
2006-04-20  1:45 erik quanstrom
2006-04-20  3:03 ` Michael Baldwin
2006-04-20  5:58   ` Charles Forsyth
2006-04-21 11:34   ` Bruce Ellis
2006-04-21 15:46     ` Skip Tavakkolian
2006-04-21 15:47     ` Jack Johnson
2006-04-19  8:19 YAMANASHI Takeshi
2006-04-19  3:27 Mike Haertel
2006-04-19  3:04 erik quanstrom
2006-04-19  2:47 erik quanstrom
2006-04-19  2:35 erik quanstrom
2006-04-19  3:53 ` Russ Cox
2006-04-19 19:34 ` Roman Shaposhnick
2006-04-19 19:42   ` Bruce Ellis
2006-04-20  1:07     ` Roman Shaposhnick
2006-04-20  2:02       ` Jack Johnson
2006-04-19 19:45   ` Charles Forsyth
2006-04-19 21:16   ` Brantley Coile
2006-04-19 21:46   ` quanstro
2006-04-20  1:03     ` rog
2006-04-20  6:08       ` Charles Forsyth
2006-04-20 15:59         ` rog
2006-04-20  4:02     ` Roman Shaposhnick
2006-04-17 22:07 Bakul Shah
2006-04-18  0:01 ` Russ Cox
2006-04-18 14:36   ` Gorka guardiola
2006-04-18 15:47     ` Russ Cox
2006-04-18 14:45       ` Ronald G Minnich
2006-04-18 16:12         ` Charles Forsyth
2006-04-18 16:42           ` andrey mirtchovski
2006-04-18 16:46           ` Bruce Ellis
2006-04-18 16:47             ` Charles Forsyth
2006-04-18 17:41               ` Brantley Coile
2006-04-18 17:46               ` David Leimbach
2006-04-18 17:55                 ` Bruce Ellis
2006-04-18 18:06                   ` Francisco J Ballesteros
2006-04-18 22:37                     ` Skip Tavakkolian
2006-04-18 18:54                   ` Charles Forsyth
2006-04-18 19:22                     ` David Leimbach
2006-04-18 20:14                       ` lucio
2006-04-18 20:34                       ` Russ Cox
2006-04-18 19:52                         ` David Leimbach
2006-04-20 21:16                         ` Latchesar Ionkov
2006-04-18 20:45                       ` Ronald G Minnich
2006-04-18 21:08                         ` David Leimbach
2006-04-18 21:39                       ` Roman Shaposhnick
2006-04-18 21:54                         ` David Leimbach
2006-04-18 23:19                           ` Brantley Coile
2006-04-19  1:05                             ` Roman Shaposhnick
2006-04-19 14:17                             ` David Leimbach
2006-04-19 14:31                               ` Charles Forsyth
2006-04-19 15:32                               ` Chad Dougherty
2006-04-19 15:45                                 ` David Leimbach
2006-04-19 15:57                                   ` Federico G. Benavento
2006-04-19 17:45                                     ` David Leimbach
2006-04-19 23:56                                       ` geoff
2006-04-19 16:49                                   ` Russ Cox
2006-04-19 17:50                                     ` David Leimbach
2006-04-19 17:55                                       ` Federico G. Benavento
2006-04-19 18:45                                       ` Charles Forsyth
2006-04-19 18:55                                         ` David Leimbach
2006-04-18 23:27                           ` Roman Shaposhnick
2006-04-18 23:29                           ` Federico G. Benavento
2006-04-18 23:48                             ` Lyndon Nerenberg
2006-04-19 14:25                             ` David Leimbach
2006-04-19 14:31                               ` Ronald G Minnich
2006-04-19 15:51                                 ` Tim Wiess
2006-04-19 19:53                                 ` Wes Kussmaul
2006-04-20 14:39                                   ` Ronald G Minnich
2006-04-20 15:50                                     ` Jack Johnson
2006-04-20 21:20                                       ` Ronald G Minnich
2006-04-20 21:42                                         ` Dan Cross
2006-04-20 22:06                                           ` Brantley Coile
2006-04-21  3:43                                           ` Ronald G Minnich
2006-04-21  4:37                                             ` Dan Cross
2006-04-21 16:08                                               ` Ronald G Minnich
2006-04-20 22:09                                         ` Wes Kussmaul
2006-04-20 23:09                                           ` Charles Forsyth
2006-04-21  3:45                                           ` Ronald G Minnich
2006-04-21  4:31                                             ` Dan Cross
2006-04-21 13:36                                               ` Christoph Lohmann
2006-04-21  4:46                                             ` lucio
2006-04-18 19:34                     ` jmk
2006-04-18 19:52                       ` David Leimbach
2006-04-18 20:34                     ` Roman Shaposhnick
2006-04-18 21:04                     ` Dan Cross
2006-04-18 21:11                       ` Charles Forsyth
2006-04-18 21:16                         ` Dan Cross
2006-04-18 21:21                         ` David Leimbach
2006-04-18 21:24                       ` David Leimbach
2006-04-19  2:53                         ` geoff
2006-04-19  3:16                           ` Dan Cross
2006-04-19  3:28                             ` geoff
2006-04-20 22:35                           ` Roman Shaposhnick
2006-04-19  3:02                         ` Dan Cross
2006-04-18 20:44                 ` Ronald G Minnich
2006-04-20  3:10                   ` LiteStar numnums
2006-04-18 16:48             ` Charles Forsyth
2006-04-18 16:58               ` Bruce Ellis
2006-04-18 17:02             ` uriel
2006-04-18 17:30               ` Bruce Ellis
2006-04-18 20:21           ` Richard Miller
2006-04-18 21:10             ` Charles Forsyth
2006-04-19  1:14             ` geoff
2006-04-19 12:49               ` Richard Miller
2006-04-19 13:21                 ` Charles Forsyth
2006-04-18 16:17       ` Dave Eckhardt
2006-04-18 19:17         ` Lyndon Nerenberg
2006-04-19  0:28   ` Bakul Shah
2006-04-19  1:45     ` Russ Cox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).