On 2/5/17 6:07 , a b wrote:
> I would like to build SmartOS-live which will have SVR4 packaging
> (pkgadd(1M) and friends back in /usr/sbin and /usr/bin. 
> 
> SmartOS purposely removes these from the RAMDisk  image,  and  so
> far,  I  have  been  unsuccessful  where  they  are  removed  and
> excluded. 
> 
> What do I need to modify to get those back in?

The list of files included in the build from illumos is based on the
'manifest' file in the root of the illumos-joyent repository. Adding to
them will allow you to proceed.

> Other option would be to bootstrap SVR4 packaging in  /opt/local,
> or  some  other  location  in  /opt. Thus, I have hunted down and
> patched  every  single  location  in  usr/src/cmd/svr4pkg   which
> referenced /usr, and still pkgadd(1M) complains thus:
> 
> # pkgadd -a /var/spool/pkg/SUNWpkgcmdsr/reloc/var/sadm/install/admin/default 
> SUNWpkgcmdsr
> ## Waiting for up to <300> seconds for package administration commands to 
> become available (another user is administering packages)
> pkgadd: ERROR: ERROR: Unable to acquire package administration lock for this 
> system; try again later
> pkgadd: ERROR: Unable to lock this zone for administration
> 
> 1 package was not processed!
> 
> running truss(1) on this I get that it's trying to run /usr/bin/pkgadm(1M):
> 
> 6196:   access("/usr/bin/pkgadm", X_OK)                 Err#2 ENOENT
> 6196:   fstat64(2, 0x08045220)                          = 0
> ## Waiting for up to <300> seconds for package administration commands to 
> become available (another user is administering packages)6196:        
> write(2, " # #   W a i t i n g   f".., 131)  = 131
> 
> And so, thinking about this  further,  since  /usr  seems  to  be
> deeply  ingrained  into  SVR4  packaging, rather than hack my way
> around this, this would be a non-existent problem if I only  knew
> where  to  look  to  not  have  SVR4  packaging excluded from the
> RAMDisk when doing `gmake world`. 
> 
> While option 1 with RAMDisk would be ideal, I'm  not  opposed  to
> option 2 (/opt inside of a zone).

I suspect that option 2 will provide you a better long-term experience
and that you should fork them from illumos and do what you want to work
in an arbitrary prefix. Especially as you'll likely need to come up with
something to handle all the existing packages that might assume /usr is
writable. This also gets you out of having to build a custom release.

Robert


-------------------------------------------
smartos-discuss
Archives: https://www.listbox.com/member/archive/184463/=now
RSS Feed: https://www.listbox.com/member/archive/rss/184463/25769125-55cfbc00
Modify Your Subscription: 
https://www.listbox.com/member/?member_id=25769125&id_secret=25769125-7688e9fb
Powered by Listbox: http://www.listbox.com

Reply via email to