defining ports LOCKDIR

classic Classic list List threaded Threaded
14 messages Options
Reply | Threaded
Open this post in threaded view
|

defining ports LOCKDIR

Marc Espie-2
Historically, I did leave LOCKDIR empty in bsd.port.mk.
Now, I'm wondering if I should define it to something such as
/tmp/portslocks ?

My assumption was that it would be difficult to be certain that dotlocks could
be created anywhere.  But it seems that most machines have local /tmp/ these
days. And anyways, those that don't could define
LOCKDIR =
to remove the locking mechanism anyways...

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Antoine Jacoutot-7
On Wed, 16 Jun 2010, Marc Espie wrote:

> Historically, I did leave LOCKDIR empty in bsd.port.mk.
> Now, I'm wondering if I should define it to something such as
> /tmp/portslocks ?
>
> My assumption was that it would be difficult to be certain that dotlocks could
> be created anywhere.  But it seems that most machines have local /tmp/ these
> days. And anyways, those that don't could define
> LOCKDIR =
> to remove the locking mechanism anyways...

For what it's worth, I'm all for it being defined by default.
/tmp seems sensible if daily(8) does not interfere.

--
Antoine

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Stuart Henderson
On 2010/06/16 13:45, Antoine Jacoutot wrote:

> On Wed, 16 Jun 2010, Marc Espie wrote:
>
> > Historically, I did leave LOCKDIR empty in bsd.port.mk.
> > Now, I'm wondering if I should define it to something such as
> > /tmp/portslocks ?
> >
> > My assumption was that it would be difficult to be certain that dotlocks could
> > be created anywhere.  But it seems that most machines have local /tmp/ these
> > days. And anyways, those that don't could define
> > LOCKDIR =
> > to remove the locking mechanism anyways...
>
> For what it's worth, I'm all for it being defined by default.
> /tmp seems sensible if daily(8) does not interfere.

3 days is a bit short on some arch. /var/tmp gives you 7 days,
but isn't cleared at boot...

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Marc Espie-2
In reply to this post by Antoine Jacoutot-7
On Wed, Jun 16, 2010 at 01:45:30PM +0200, Antoine Jacoutot wrote:

> On Wed, 16 Jun 2010, Marc Espie wrote:
>
> > Historically, I did leave LOCKDIR empty in bsd.port.mk.
> > Now, I'm wondering if I should define it to something such as
> > /tmp/portslocks ?
> >
> > My assumption was that it would be difficult to be certain that dotlocks could
> > be created anywhere.  But it seems that most machines have local /tmp/ these
> > days. And anyways, those that don't could define
> > LOCKDIR =
> > to remove the locking mechanism anyways...
>
> For what it's worth, I'm all for it being defined by default.
> /tmp seems sensible if daily(8) does not interfere.

I think organizing it in a subdirectory runs risk of less interferences with
other stuff, for what it's worth.

(and yep, your comments prompted this)

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Marc Espie-2
In reply to this post by Stuart Henderson
On Wed, Jun 16, 2010 at 12:51:20PM +0100, Stuart Henderson wrote:

> On 2010/06/16 13:45, Antoine Jacoutot wrote:
> > On Wed, 16 Jun 2010, Marc Espie wrote:
> >
> > > Historically, I did leave LOCKDIR empty in bsd.port.mk.
> > > Now, I'm wondering if I should define it to something such as
> > > /tmp/portslocks ?
> > >
> > > My assumption was that it would be difficult to be certain that dotlocks could
> > > be created anywhere.  But it seems that most machines have local /tmp/ these
> > > days. And anyways, those that don't could define
> > > LOCKDIR =
> > > to remove the locking mechanism anyways...
> >
> > For what it's worth, I'm all for it being defined by default.
> > /tmp seems sensible if daily(8) does not interfere.
>
> 3 days is a bit short on some arch. /var/tmp gives you 7 days,
> but isn't cleared at boot...
>
daily could be set to ignore those... after all, it already ignores some other
stuff.

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Antoine Jacoutot-7
On Wed, 16 Jun 2010, Marc Espie wrote:
> > 3 days is a bit short on some arch. /var/tmp gives you 7 days,
> > but isn't cleared at boot...
> >
> daily could be set to ignore those... after all, it already ignores some other
> stuff.

Sure, I was just pointing that one needed to be careful ;-)

--
Antoine

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Bret S. Lambert-2
On Wed, Jun 16, 2010 at 02:02:37PM +0200, Antoine Jacoutot wrote:
> On Wed, 16 Jun 2010, Marc Espie wrote:
> > > 3 days is a bit short on some arch. /var/tmp gives you 7 days,
> > > but isn't cleared at boot...
> > >
> > daily could be set to ignore those... after all, it already ignores some other
> > stuff.
>
> Sure, I was just pointing that one needed to be careful ;-)

What about /var/run? cleared on boot, isn't ratfucked by /etc/daily.

>
> --
> Antoine

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Marc Espie-2
On Wed, Jun 16, 2010 at 02:11:47PM +0200, Bret S. Lambert wrote:

> On Wed, Jun 16, 2010 at 02:02:37PM +0200, Antoine Jacoutot wrote:
> > On Wed, 16 Jun 2010, Marc Espie wrote:
> > > > 3 days is a bit short on some arch. /var/tmp gives you 7 days,
> > > > but isn't cleared at boot...
> > > >
> > > daily could be set to ignore those... after all, it already ignores some other
> > > stuff.
> >
> > Sure, I was just pointing that one needed to be careful ;-)
>
> What about /var/run? cleared on boot, isn't ratfucked by /etc/daily.

!root...

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Bret S. Lambert-2
On Wed, Jun 16, 2010 at 02:15:37PM +0200, Marc Espie wrote:

> On Wed, Jun 16, 2010 at 02:11:47PM +0200, Bret S. Lambert wrote:
> > On Wed, Jun 16, 2010 at 02:02:37PM +0200, Antoine Jacoutot wrote:
> > > On Wed, 16 Jun 2010, Marc Espie wrote:
> > > > > 3 days is a bit short on some arch. /var/tmp gives you 7 days,
> > > > > but isn't cleared at boot...
> > > > >
> > > > daily could be set to ignore those... after all, it already ignores some other
> > > > stuff.
> > >
> > > Sure, I was just pointing that one needed to be careful ;-)
> >
> > What about /var/run? cleared on boot, isn't ratfucked by /etc/daily.
>
> !root...

bitch, bitch, bitch! :p

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Stuart Henderson
In reply to this post by Marc Espie-2
On 2010/06/16 14:00, Marc Espie wrote:

> On Wed, Jun 16, 2010 at 12:51:20PM +0100, Stuart Henderson wrote:
> > On 2010/06/16 13:45, Antoine Jacoutot wrote:
> > > On Wed, 16 Jun 2010, Marc Espie wrote:
> > >
> > > > Historically, I did leave LOCKDIR empty in bsd.port.mk.
> > > > Now, I'm wondering if I should define it to something such as
> > > > /tmp/portslocks ?
> > > >
> > > > My assumption was that it would be difficult to be certain that dotlocks could
> > > > be created anywhere.  But it seems that most machines have local /tmp/ these
> > > > days. And anyways, those that don't could define
> > > > LOCKDIR =
> > > > to remove the locking mechanism anyways...
> > >
> > > For what it's worth, I'm all for it being defined by default.
> > > /tmp seems sensible if daily(8) does not interfere.
> >
> > 3 days is a bit short on some arch. /var/tmp gives you 7 days,
> > but isn't cleared at boot...
> >
> daily could be set to ignore those... after all, it already ignores some other
> stuff.
>

yep. I would be happy with that.

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

J.C. Roberts-3
In reply to this post by Marc Espie-2
On Wed, 16 Jun 2010 13:38:12 +0200 Marc Espie <[hidden email]> wrote:

>
> Historically, I did leave LOCKDIR empty in bsd.port.mk.
> Now, I'm wondering if I should define it to something such as
> /tmp/portslocks ?
>
> My assumption was that it would be difficult to be certain that
> dotlocks could be created anywhere.  But it seems that most machines
> have local /tmp/ these days. And anyways, those that don't could
> define LOCKDIR =
> to remove the locking mechanism anyways...
>

It might be an uneducated question, but why not place it under pobj?
Do we really want automatic purging on reboot/7-days/whatever?
Do we really want to make an exception to daily for LOCKDIR?

I can't say it's a great idea, but I've been experimenting with a disk
layout like:
        a 1G /
        b 12G [swap]
        c
        d 12G /tmp
        e 24G /var
        f 2G /usr
        g 2G /usr/X11R6
        h 24G /usr/local
        i 2G /usr/src
        j 2G /usr/obj
        k 32G /usr/pobj
        l 2G /usr/ports
        m 2G /usr/xenocara
        n 2G /usr/xobj
        o 128G /home
        p 128G /arc

disfiles and built packages get saved to /arc/OpenBSD/... and get
regularly archived/backed-up. If something goes wrong, or I do something
stupid (most likely the latter), the /usr/pobj partition has at least a
fighting chance of saving my ass.

Stuffing the LOCKDIR under pobj (where ever you keep pobj) seems to
make more sense and requires fewer changes.

        jcr

--
The OpenBSD Journal - http://www.undeadly.org

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Antoine Jacoutot-7
On Wed, 16 Jun 2010, J.C. Roberts wrote:
> Stuffing the LOCKDIR under pobj (where ever you keep pobj) seems to
> make more sense and requires fewer changes.

Some have obj on nfs.

--
Antoine

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Marc Espie-2
I should have been more specific. This is not a vote as to where we
should put the default.

If you think of the constraints (usually not NFS, user-writable), there
are about two locations that make sense: /tmp or /var/tmp.

Also remember that it makes no sense for those locks to survive reboot.
So /tmp is the only location that makes sense.

Remember that it is a default.

Stuart's remark wrt /etc/daily is good, but /etc/daily can be fixed.

What do you say ? default, or not default ?

Reply | Threaded
Open this post in threaded view
|

Re: defining ports LOCKDIR

Sean Kennedy-5
Marc, Everyone.

I say  /tmp

This; if anything, is what makes OpenBSD - Unix -.
The correct usage of /tmp

/etc/daily  I strongly urge be fixed.

-sean

> Date: Wed, 16 Jun 2010 17:17:40 +0200
> From: [hidden email]
> To: [hidden email]
> Subject: Re: defining ports LOCKDIR
>
> I should have been more specific. This is not a vote as to where we
> should put the default.
>
> If you think of the constraints (usually not NFS, user-writable), there
> are about two locations that make sense: /tmp or /var/tmp.
>
> Also remember that it makes no sense for those locks to survive reboot.
> So /tmp is the only location that makes sense.
>
> Remember that it is a default.
>
> Stuart's remark wrt /etc/daily is good, but /etc/daily can be fixed.
>
> What do you say ? default, or not default ?




A computer without COBOL and FORTRAN is like a piece of
chocolate cake without ketchup or mustard."  unix fortune cookie.



_________________________________________________________________
Look 'em in the eye: FREE Messenger video chat
http://go.microsoft.com/?linkid=9734386