new kind of info organizer, on OpenBSD: OneModel

2016-01-27 Thread luke call

Short version: I have carefully tested OpenBSD installation
instructions for an extremely flexible personal
organizer program.  It does things differently, is text-mode/keyboard
only (for now), doesn't require X, and is very efficient to use.  It
doesn't have pretty knobs and buttons but is very good at what it
does.  Details on what it is now, what it is not, and plans for future
are at http://onemodel.org, especially under the About link and
sublinks.


Detailed version:
If you've ever used emacs org-mode, to-do list programs or the like,
this might be of interest.  It is Free.  It flexibly, easily treats
knowledge as data in an object network, instead of just as piles of
words, and is physically very efficient to navigate and use (keyboard
only).

I've tested carefully and used it for some months on OpenBSD.  I think
it could be useful to some here.  It is the best personal organizer I
have ever used: I wrote it to suit myself (& hopefully others: that's
what I'm trying to find out).  It is oriented to those who like the
keyboard & can read the screen, and who want to record notes and
manipulate them *fast*, in simple or arbitrarily complex structures:
basically I try to break knowledge down to an atomic level--
relationships and attributes, aka an object model--as a side effect of
simply using the system.  Everything one needs to know (or nearly so)
is shown on the screen, and ... I hope some of you love it.

There's a free .jar file download, or source code and complete
instructions at github.  The source is AGPL (no offense I hope; I want
any mods to come back, for all the work I've put in).

I didn't want to package it (put it into ports) yet, until I can see if
reaction and interest warrant that

More descriptive info & screen shots are at http://www.onemodel.org .
Look under "About", "what it is today", "future", through to the FAQs
if you're really interested in the thinking behind it.

Feedback (or flames?) welcome: this is a learning process and I hope to
make it as useful to others as I can.  I invite discussion at the 
OneModel.org mailing lists (under the Community link) to avoid the topic 
becoming annoying on this list.


Best regards,

Luke A. Call
--
A Free, fast personal organizer for touch typists:  if you ever liked
to-do list programs, collapsible outlines, or emacs org-mode, you might
love this: http://www.onemodel.org (no mobile support yet).

Things I'd like to say to more people:  (updated 2016-1-9)
http://www.onemodel.org/1/e-9223372036854618449.html .



Re: can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Stuart Henderson
On 2016-01-27, Antoine Jacoutot  wrote:
> On Wed, Jan 27, 2016 at 12:30:08PM +0100, Reyk Floeter wrote:
>> On Wed, Jan 27, 2016 at 06:12:22AM -0500, Jiri B wrote:
>> > Hi,
>> > 
>> > I can't run multiple instances of httpd via rc.d as I can't distinguish
>> > between httpd instances. ps aux never show flags passed to httpd.
>> > 
>> > Could httpd be extended to show flags like sshd does it?
>> > 
>> > root 15681  0.0  0.1  1196  2308 ??  Ssp   12:08PM0:00.05 httpd: 
>> > parent (httpd)
>> > 
>> > vs
>> > 
>> > root 17247  0.0  0.1   920  1376 ??  Ss12:09PM0:00.03 
>> > /usr/sbin/sshd -f /etc/ssh/test_sshd_config
>> > 
>> > Or is there any other way to distinguish between two httpd instances?
>> > 
>> > j.
>> > 
>> 
>> Interesting point, I never thought about it.
>
> That's not httpd specific. Most of our privilege separated daemons do that 
> and it sucks :-)

This does the trick. It probably doesn't make sense to run multiple
copies of all of the privsep daemons though I see definite use cases
for httpd, snmpd [v4 and v6 need separate daemons], and possibly some
others, but it would be better to keep them all in-sync..

Index: etc/rc.d/httpd
===
RCS file: /cvs/src/etc/rc.d/httpd,v
retrieving revision 1.3
diff -u -p -r1.3 httpd
--- etc/rc.d/httpd  22 Jul 2014 17:37:16 -  1.3
+++ etc/rc.d/httpd  27 Jan 2016 22:22:11 -
@@ -6,6 +6,4 @@ daemon="/usr/sbin/httpd"
 
 . /etc/rc.d/rc.subr
 
-pexp="httpd: parent.*"
-
 rc_cmd $1
Index: usr.sbin/httpd/httpd.c
===
RCS file: /cvs/src/usr.sbin/httpd/httpd.c,v
retrieving revision 1.53
diff -u -p -r1.53 httpd.c
--- usr.sbin/httpd/httpd.c  3 Dec 2015 11:46:25 -   1.53
+++ usr.sbin/httpd/httpd.c  27 Jan 2016 22:22:11 -
@@ -248,7 +248,6 @@ main(int argc, char *argv[])
 
proc_init(ps, procs, nitems(procs));
 
-   setproctitle("parent");
log_procinit("parent");
 
if (pledge("stdio rpath wpath cpath inet dns proc ioctl sendfd",



Re: can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Reyk Floeter
On Wed, Jan 27, 2016 at 01:49:30PM +0100, Antoine Jacoutot wrote:
> On Wed, Jan 27, 2016 at 12:30:08PM +0100, Reyk Floeter wrote:
> > On Wed, Jan 27, 2016 at 06:12:22AM -0500, Jiri B wrote:
> > > Hi,
> > > 
> > > I can't run multiple instances of httpd via rc.d as I can't distinguish
> > > between httpd instances. ps aux never show flags passed to httpd.
> > > 
> > > Could httpd be extended to show flags like sshd does it?
> > > 
> > > root 15681  0.0  0.1  1196  2308 ??  Ssp   12:08PM0:00.05 httpd: 
> > > parent (httpd)
> > > 
> > > vs
> > > 
> > > root 17247  0.0  0.1   920  1376 ??  Ss12:09PM0:00.03 
> > > /usr/sbin/sshd -f /etc/ssh/test_sshd_config
> > > 
> > > Or is there any other way to distinguish between two httpd instances?
> > > 
> > > j.
> > > 
> > 
> > Interesting point, I never thought about it.
> 
> That's not httpd specific. Most of our privilege separated daemons do that 
> and it sucks :-)
> 

Well, we "tradionally" had setproctitle("[priv]") in the parent.  I
changed the tradition to setproctitle("parent").

I have no objections with changing this in the parent (but keeping the
setproctitles in the children) to either the default (all command line
flags) or to something like setproctitle("parent, %s", conffile).
Command line flags suck and I don't think that -d or -v would be
helpful in the output, so I prefer the latter.

All rc scripts would have to be adjusted by somebody with better rc-fu.

Opinions?

Reyk



Re: can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Reyk Floeter
> On 27.01.2016, at 23:31, Stuart Henderson  wrote:
>
> On 2016-01-27, Antoine Jacoutot  wrote:
>> On Wed, Jan 27, 2016 at 12:30:08PM +0100, Reyk Floeter wrote:
>>> On Wed, Jan 27, 2016 at 06:12:22AM -0500, Jiri B wrote:
 Hi,

 I can't run multiple instances of httpd via rc.d as I can't distinguish
 between httpd instances. ps aux never show flags passed to httpd.

 Could httpd be extended to show flags like sshd does it?

 root 15681  0.0  0.1  1196  2308 ??  Ssp   12:08PM0:00.05 httpd:
parent (httpd)

 vs

 root 17247  0.0  0.1   920  1376 ??  Ss12:09PM0:00.03
/usr/sbin/sshd -f /etc/ssh/test_sshd_config

 Or is there any other way to distinguish between two httpd instances?

 j.

>>>
>>> Interesting point, I never thought about it.
>>
>> That's not httpd specific. Most of our privilege separated daemons do that
and it sucks :-)
>
> This does the trick. It probably doesn't make sense to run multiple
> copies of all of the privsep daemons though I see definite use cases
> for httpd, snmpd [v4 and v6 need separate daemons], and possibly some
> others, but it would be better to keep them all in-sync..
>

Fine, this is what I suggested as the first option.

But let's do it everywhere and not just for httpd -
don't use setproctitle in the parent process.

It does make sense for many more privsep daemons, especially in combination
with rdomains (ntpd, iked, …). bgpd would probably not need it, but it does
not harm
and I'd prefer to change it for consistency (please don't forget that we try
to keep
the daemons synced somehow - it's an ecosystem).

Reyk

> Index: etc/rc.d/httpd
> ===
> RCS file: /cvs/src/etc/rc.d/httpd,v
> retrieving revision 1.3
> diff -u -p -r1.3 httpd
> --- etc/rc.d/httpd22 Jul 2014 17:37:16 -  1.3
> +++ etc/rc.d/httpd27 Jan 2016 22:22:11 -
> @@ -6,6 +6,4 @@ daemon="/usr/sbin/httpd"
>
> . /etc/rc.d/rc.subr
>
> -pexp="httpd: parent.*"
> -
> rc_cmd $1
> Index: usr.sbin/httpd/httpd.c
> ===
> RCS file: /cvs/src/usr.sbin/httpd/httpd.c,v
> retrieving revision 1.53
> diff -u -p -r1.53 httpd.c
> --- usr.sbin/httpd/httpd.c3 Dec 2015 11:46:25 -   1.53
> +++ usr.sbin/httpd/httpd.c27 Jan 2016 22:22:11 -
> @@ -248,7 +248,6 @@ main(int argc, char *argv[])
>
>   proc_init(ps, procs, nitems(procs));
>
> - setproctitle("parent");
>   log_procinit("parent");
>
>   if (pledge("stdio rpath wpath cpath inet dns proc ioctl sendfd",



Re: ipsec between three networks

2016-01-27 Thread mxb
OSPF is not right protocol if you scale to more than 3 sites and want
influence routing.
BGP will do a better job in this situation.

> On 27 jan. 2016, at 03:39, Dewey Hylton  wrote:
>
> my current working configuration has 3 sites; each site is connected to the
> others, and routing is handled via ospfd.



Re: can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Antoine Jacoutot
> Well, we "tradionally" had setproctitle("[priv]") in the parent.  I
> changed the tradition to setproctitle("parent").
> 
> I have no objections with changing this in the parent (but keeping the
> setproctitles in the children) to either the default (all command line
> flags) or to something like setproctitle("parent, %s", conffile).
> Command line flags suck and I don't think that -d or -v would be
> helpful in the output, so I prefer the latter.

"-v" is helpful at least for rc.d which needs to match the full args list by 
default

> All rc scripts would have to be adjusted by somebody with better rc-fu.

Actually if things are properly done, the non default pexp line in the rc.d 
scripts should just be removed and that's it.

-- 
Antoine



Re: can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Antoine Jacoutot
> This does the trick. It probably doesn't make sense to run multiple
> copies of all of the privsep daemons though I see definite use cases
> for httpd, snmpd [v4 and v6 need separate daemons], and possibly some
> others, but it would be better to keep them all in-sync..

Yes, if we go this way, please let's keep them in sync.
There's always some cases where you'd like to run multiple copies of a daemon 
-- even temporarily (and even for the non obvious ones).

> Index: etc/rc.d/httpd
> ===
> RCS file: /cvs/src/etc/rc.d/httpd,v
> retrieving revision 1.3
> diff -u -p -r1.3 httpd
> --- etc/rc.d/httpd22 Jul 2014 17:37:16 -  1.3
> +++ etc/rc.d/httpd27 Jan 2016 22:22:11 -
> @@ -6,6 +6,4 @@ daemon="/usr/sbin/httpd"
>  
>  . /etc/rc.d/rc.subr
>  
> -pexp="httpd: parent.*"
> -

\o/ this is what I expected :-)

>  rc_cmd $1
> Index: usr.sbin/httpd/httpd.c
> ===
> RCS file: /cvs/src/usr.sbin/httpd/httpd.c,v
> retrieving revision 1.53
> diff -u -p -r1.53 httpd.c
> --- usr.sbin/httpd/httpd.c3 Dec 2015 11:46:25 -   1.53
> +++ usr.sbin/httpd/httpd.c27 Jan 2016 22:22:11 -
> @@ -248,7 +248,6 @@ main(int argc, char *argv[])
>  
>   proc_init(ps, procs, nitems(procs));
>  
> - setproctitle("parent");
>   log_procinit("parent");
>  
>   if (pledge("stdio rpath wpath cpath inet dns proc ioctl sendfd",
> 

-- 
Antoine



Re: rc.d and rtable

2016-01-27 Thread Jiri B
On Wed, Jan 27, 2016 at 01:40:14PM +0100, Antoine Jacoutot wrote:
> On Wed, Jan 27, 2016 at 06:47:57AM -0500, Jiri B wrote:
> > Would it be worth to extend rc.d for rtable knobs?
> > 
> > - daemon_rtable varible
> > - rc_* functions (route exec, pgrep/pkill -T $rtable...)
> > 
> > Or are routing tables not much used thus not worth to make
> > rc.d more complicated?
> 
> There has been several discussions about this. No decision made though.
> If you can find a nice way to implement it, I can have a look.

rc.d framework is so nice... not sure if this is nice way but it
works. Maybe check for existing rtable is not great.

Index: etc/rc.d/rc.subr
===
RCS file: /cvs/src/etc/rc.d/rc.subr,v
retrieving revision 1.105
diff -u -p -r1.105 rc.subr
--- etc/rc.d/rc.subr21 Dec 2015 10:18:05 -  1.105
+++ etc/rc.d/rc.subr27 Jan 2016 17:57:16 -
@@ -130,7 +130,7 @@ _rc_parse_conf() {
while IFS=' ' read -r _l; do
[[ $_l == [!#=]*=* ]] || continue
_key=${_l%%*([[:blank:]])=*}
-   [[ $_key == *_@(flags|user|timeout) ]] || \
+   [[ $_key == *_@(flags|rtable|user|timeout) ]] || \
[[ " ${_allowed_keys[*]} " == *" $_key "* ]] || 
\
continue
[[ $_key == "" ]] && continue
@@ -154,15 +154,15 @@ rc_start() {
 }
 
 rc_check() {
-   pgrep -q -xf "${pexp}"
+   pgrep -T ${daemon_rtable} -q -xf "${pexp}"
 }
 
 rc_reload() {
-   pkill -HUP -xf "${pexp}"
+   pkill -HUP -T ${daemon_rtable} -xf "${pexp}"
 }
 
 rc_stop() {
-   pkill -xf "${pexp}"
+   pkill -T ${daemon_rtable} -xf "${pexp}"
 }
 
 rc_cmd() {
@@ -172,6 +172,10 @@ rc_cmd() {
[ X"${rc_usercheck}" != X"NO" -a X"$1" = "Xcheck" ] || \
_rc_err "$0: need root privileges"
 
+   if ! route -T ${daemon_rtable} -n show >/dev/null 2>&1; then
+   _rc_err "$0: rtable ${daemon_rtable} does not exist"
+   fi
+   
if _rc_not_supported start || _rc_not_supported stop; then
rc_restart=NO
fi
@@ -259,12 +263,14 @@ _RC_RUNFILE=${_RC_RUNDIR}/${_name}
 _rc_do _rc_parse_conf
 
 eval _rcflags=\${${_name}_flags}
+eval _rcrtable=\${${_name}_rtable}
 eval _rcuser=\${${_name}_user}
 eval _rctimeout=\${${_name}_timeout}
 
 # set default values; duplicated in rcctl(8)
 getcap -f /etc/login.conf ${_name} 1>/dev/null 2>&1 && \
daemon_class=${_name} || daemon_class=daemon
+[ -z "${daemon_rtable}" ] && daemon_rtable=0
 [ -z "${daemon_user}" ] && daemon_user=root
 [ -z "${daemon_timeout}" ] && daemon_timeout=30
 
@@ -273,6 +279,7 @@ getcap -f /etc/login.conf ${_name} 1>/de
unset _rcflags
 
 [ -n "${_rcflags}" ] && daemon_flags=${_rcflags}
+[ -n "${_rcrtable}" ] && daemon_rtable=${_rcrtable}
 [ -n "${_rcuser}" ] && daemon_user=${_rcuser}
 [ -n "${_rctimeout}" ] && daemon_timeout=${_rctimeout}
 
@@ -280,9 +287,13 @@ if [ -n "${_RC_DEBUG}" ]; then
echo -n "${_name}_flags "
[ -n "${_rcflags}" ] || echo -n "empty, using default "
echo ">${daemon_flags}<"
+   echo -n "${_name}_rtable "
+   [ -n "${_rcrtable}" ] || echo -n "empty, using default "
+   echo ">${daemon_rtable}<"   
 fi
 
 readonly daemon_class
-unset _rcflags _rcuser _rctimeout
+unset _rcflags _rcrtable _rcuser _rctimeout
 pexp="${daemon}${daemon_flags:+ ${daemon_flags}}"
-rcexec="su -l -c ${daemon_class} -s /bin/sh ${daemon_user} -c"
+rcexec="route -T ${daemon_rtable} exec su -l -c ${daemon_class} -s /bin/sh 
${daemon_user} -c"
+
Index: usr.sbin/rcctl/rcctl.sh
===
RCS file: /cvs/src/usr.sbin/rcctl/rcctl.sh,v
retrieving revision 1.88
diff -u -p -r1.88 rcctl.sh
--- usr.sbin/rcctl/rcctl.sh 24 Jan 2016 08:51:50 -  1.88
+++ usr.sbin/rcctl/rcctl.sh 27 Jan 2016 17:57:20 -
@@ -220,7 +220,7 @@ svc_get()
[ -n "${_svc}" ] || return
 
local _status=0 _val _var=$2
-   local daemon_class daemon_flags daemon_timeout daemon_user
+   local daemon_class daemon_flags daemon_rtable daemon_timeout daemon_user
 
if svc_is_special ${_svc}; then
daemon_flags="$(eval echo \${${_svc}})"
@@ -246,6 +246,12 @@ svc_get()
[ -z "${daemon_flags}" ] && \
daemon_flags="$(svc_getdef ${_svc} 
flags)"
fi
+   if [ -z "${_var}" -o "${_var}" = "rtable" ]; then
+   [ -z "${daemon_rtable}" ] && \
+   daemon_rtable="$(eval echo 
\"\${${_svc}_rtable}\")"
+   [ -z "${daemon_rtable}" ] && \
+   daemon_rtable="$(svc_getdef ${_svc} 
rtable)"
+   fi
if [ 

Re: issue with xnf running 15th jan snapshot on Xen v. 4.5.1

2016-01-27 Thread Imre Oolberg

Hi!

I write here for the record so possible arvhive readers know that this 
thread ended in couple of private emails with developer and he fixed 
this problem. Short version and what i can narrate is that i used 
GENERIC i.e. single cpu kernel and my situation was specific to this 
kernel. Had i used GENERIC.MP i would have not noticed it. Now i happily 
run OpenBSD on Xen too, .MP or not .MP, thanks!



Imre


On 2016-01-19 19:48, Mike Belopuhov wrote:

Hi,

Thanks for taking your time to test and write a report.  I've fixed
a few issues since then and was going to ask you to test a -current
kernel.  Could you also please send bug reports like this to bugs@
rather than misc@.

Thank you!

Cheers,
Mike




Re: Willing to help

2016-01-27 Thread lists
Tue, 26 Jan 2016 10:51:09 -0600 Adam Thompson 
> On 16-01-26 10:32 AM, Peter Hessler wrote:
> > On 2016 Jan 26 (Tue) at 08:13:22 -0600 (-0600), Edgar Pettijohn wrote:  
> > :> * adduser(8)/useradd(8):
> > :>   Needs to be unified into one single  
> >
> > One binary, with symlinks.  Both methods should still work, however.  
> 
> $0.02:
> 
>  s/sym/hard /g
> 
> might satisfy a larger percentage of people...

before a program can be named, it has source code and a compiler, seen
code by OpenBSD developers but not so much from misc@ discussions,
don't let quality coding distract us from fun talk



[SOLVED] with pain / was: APU2 WLE200NX ATHN0: Device timeout

2016-01-27 Thread Kapfhammer, Stefan
Hello misc,

thanks for all the hints with the WiFi problem on an
(beta testing) APU2b4 with a Compex WLE200NX
wireless mini PCIE card.

‎I spent 10th of hours in checking hardware,
configuration, reinstallation of snapshots‎, ...

Finally it works, I had nearly given up in that issue.

Yesterday I got mail from PCengines, announcing
a new BIOS for the APU2‎.


apu2_160120.zip:
 fix miniPCIe IRQ assignments, wle200nx working.
Please 
seehttp://pcengines.ch/howto.php#bios‎

At the time I bought the board, the mSATA SSD, WiFi card, pigtails and dual 
antennas‎, PCengines had the information
that I want to run OpenBSD on it. But no word, that
at this time, the combination won't work.

Now it works like a charm. :-)

Regards,

Stefan



Re: rc.d and rtable

2016-01-27 Thread Antoine Jacoutot
On Wed, Jan 27, 2016 at 12:58:48PM -0500, Jiri B wrote:
> On Wed, Jan 27, 2016 at 01:40:14PM +0100, Antoine Jacoutot wrote:
> > On Wed, Jan 27, 2016 at 06:47:57AM -0500, Jiri B wrote:
> > > Would it be worth to extend rc.d for rtable knobs?
> > > 
> > > - daemon_rtable varible
> > > - rc_* functions (route exec, pgrep/pkill -T $rtable...)
> > > 
> > > Or are routing tables not much used thus not worth to make
> > > rc.d more complicated?
> > 
> > There has been several discussions about this. No decision made though.
> > If you can find a nice way to implement it, I can have a look.
> 
> rc.d framework is so nice... not sure if this is nice way but it
> works. Maybe check for existing rtable is not great.

I'll have a look but don't hold your breath.
Thanks.
 
> Index: etc/rc.d/rc.subr
> ===
> RCS file: /cvs/src/etc/rc.d/rc.subr,v
> retrieving revision 1.105
> diff -u -p -r1.105 rc.subr
> --- etc/rc.d/rc.subr  21 Dec 2015 10:18:05 -  1.105
> +++ etc/rc.d/rc.subr  27 Jan 2016 17:57:16 -
> @@ -130,7 +130,7 @@ _rc_parse_conf() {
>   while IFS=' ' read -r _l; do
>   [[ $_l == [!#=]*=* ]] || continue
>   _key=${_l%%*([[:blank:]])=*}
> - [[ $_key == *_@(flags|user|timeout) ]] || \
> + [[ $_key == *_@(flags|rtable|user|timeout) ]] || \
>   [[ " ${_allowed_keys[*]} " == *" $_key "* ]] || 
> \
>   continue
>   [[ $_key == "" ]] && continue
> @@ -154,15 +154,15 @@ rc_start() {
>  }
>  
>  rc_check() {
> - pgrep -q -xf "${pexp}"
> + pgrep -T ${daemon_rtable} -q -xf "${pexp}"
>  }
>  
>  rc_reload() {
> - pkill -HUP -xf "${pexp}"
> + pkill -HUP -T ${daemon_rtable} -xf "${pexp}"
>  }
>  
>  rc_stop() {
> - pkill -xf "${pexp}"
> + pkill -T ${daemon_rtable} -xf "${pexp}"
>  }
>  
>  rc_cmd() {
> @@ -172,6 +172,10 @@ rc_cmd() {
>   [ X"${rc_usercheck}" != X"NO" -a X"$1" = "Xcheck" ] || \
>   _rc_err "$0: need root privileges"
>  
> + if ! route -T ${daemon_rtable} -n show >/dev/null 2>&1; then
> + _rc_err "$0: rtable ${daemon_rtable} does not exist"
> + fi
> + 
>   if _rc_not_supported start || _rc_not_supported stop; then
>   rc_restart=NO
>   fi
> @@ -259,12 +263,14 @@ _RC_RUNFILE=${_RC_RUNDIR}/${_name}
>  _rc_do _rc_parse_conf
>  
>  eval _rcflags=\${${_name}_flags}
> +eval _rcrtable=\${${_name}_rtable}
>  eval _rcuser=\${${_name}_user}
>  eval _rctimeout=\${${_name}_timeout}
>  
>  # set default values; duplicated in rcctl(8)
>  getcap -f /etc/login.conf ${_name} 1>/dev/null 2>&1 && \
>   daemon_class=${_name} || daemon_class=daemon
> +[ -z "${daemon_rtable}" ] && daemon_rtable=0
>  [ -z "${daemon_user}" ] && daemon_user=root
>  [ -z "${daemon_timeout}" ] && daemon_timeout=30
>  
> @@ -273,6 +279,7 @@ getcap -f /etc/login.conf ${_name} 1>/de
>   unset _rcflags
>  
>  [ -n "${_rcflags}" ] && daemon_flags=${_rcflags}
> +[ -n "${_rcrtable}" ] && daemon_rtable=${_rcrtable}
>  [ -n "${_rcuser}" ] && daemon_user=${_rcuser}
>  [ -n "${_rctimeout}" ] && daemon_timeout=${_rctimeout}
>  
> @@ -280,9 +287,13 @@ if [ -n "${_RC_DEBUG}" ]; then
>   echo -n "${_name}_flags "
>   [ -n "${_rcflags}" ] || echo -n "empty, using default "
>   echo ">${daemon_flags}<"
> + echo -n "${_name}_rtable "
> + [ -n "${_rcrtable}" ] || echo -n "empty, using default "
> + echo ">${daemon_rtable}<"   
>  fi
>  
>  readonly daemon_class
> -unset _rcflags _rcuser _rctimeout
> +unset _rcflags _rcrtable _rcuser _rctimeout
>  pexp="${daemon}${daemon_flags:+ ${daemon_flags}}"
> -rcexec="su -l -c ${daemon_class} -s /bin/sh ${daemon_user} -c"
> +rcexec="route -T ${daemon_rtable} exec su -l -c ${daemon_class} -s /bin/sh 
> ${daemon_user} -c"
> +
> Index: usr.sbin/rcctl/rcctl.sh
> ===
> RCS file: /cvs/src/usr.sbin/rcctl/rcctl.sh,v
> retrieving revision 1.88
> diff -u -p -r1.88 rcctl.sh
> --- usr.sbin/rcctl/rcctl.sh   24 Jan 2016 08:51:50 -  1.88
> +++ usr.sbin/rcctl/rcctl.sh   27 Jan 2016 17:57:20 -
> @@ -220,7 +220,7 @@ svc_get()
>   [ -n "${_svc}" ] || return
>  
>   local _status=0 _val _var=$2
> - local daemon_class daemon_flags daemon_timeout daemon_user
> + local daemon_class daemon_flags daemon_rtable daemon_timeout daemon_user
>  
>   if svc_is_special ${_svc}; then
>   daemon_flags="$(eval echo \${${_svc}})"
> @@ -246,6 +246,12 @@ svc_get()
>   [ -z "${daemon_flags}" ] && \
>   daemon_flags="$(svc_getdef ${_svc} 
> flags)"
>   fi
> + if [ -z "${_var}" -o "${_var}" = "rtable" ]; then
> + [ -z "${daemon_rtable}" ] && \
> +  

Re: Daily cron error in 5.7

2016-01-27 Thread giacomo
On 25.01.16, 13:02, Craig Skinner wrote:
> Hi Luciano,
> 
> On 2016-01-24 Sun 19:52 PM |, Luciano wrote:
> > run-parts: /etc/cron.daily/logrotate exited with return code 1
>   ^  ^ what are these?
I don't know. I search in the old configuration of crontab.

> 
> $ man run-parts
> man: no entry for run-parts in the manual.
Yes, It's strange for me also.

-- 
Luciano

This e-mail contains confidential and/or privileged information. If you are
not the intended recipient (or have received this e-mail in error), please
notify the sender immediately and destroy this e-mail. Any unauthorised
communication, diffusion, disclosure and copy of the material in this
e-mail is strictly forbidden.
--



Re: carp and bridge

2016-01-27 Thread sven falempin
On Tue, Jan 26, 2016 at 6:29 PM, sven falempin 
wrote:

> Dear readers,
>
> How bridge and carp interfaces works together ?
>
> can i bridge an interface that is a carpdev ?
> or should i bridge the carpdev ??
> will the different physical be advertise and
> would be able to contact the carp interface address ?
>
> Thank you for any input that would save a bit of try and error :-)
>
> --
>


For those who cares, you cannot carp a bridged interface but
you can bridge a carp ed interface. Trace and all reported.

OTHA, preempt seems to be activated by default , my sysctl is marked as =0
when i unplug the Master, slave is doing the job,
when i plug Master again it took back control, which would the preempt=1
behavior.

<<
For most scenarios it is desirable to have a well-defined master, achieved
by enabling the preempt option. Enable it on both host A and B:

# sysctl net.inet.carp.preempt=1
>>

This is cool, but if master reboot each minute ... and i want to keep the
switching fast preempt=0 is usefull,
switch is performed, alert is send, fix are made and when master is stable
it s activated again.

Cheers.



-- 
-
() ascii ribbon campaign - against html e-mail
/\



Re: rc.d and rtable

2016-01-27 Thread Claudio Jeker
On Wed, Jan 27, 2016 at 12:58:48PM -0500, Jiri B wrote:
> On Wed, Jan 27, 2016 at 01:40:14PM +0100, Antoine Jacoutot wrote:
> > On Wed, Jan 27, 2016 at 06:47:57AM -0500, Jiri B wrote:
> > > Would it be worth to extend rc.d for rtable knobs?
> > > 
> > > - daemon_rtable varible
> > > - rc_* functions (route exec, pgrep/pkill -T $rtable...)
> > > 
> > > Or are routing tables not much used thus not worth to make
> > > rc.d more complicated?
> > 
> > There has been several discussions about this. No decision made though.
> > If you can find a nice way to implement it, I can have a look.
> 
> rc.d framework is so nice... not sure if this is nice way but it
> works. Maybe check for existing rtable is not great.

If I see this correctly you add a foo_rtable variable to rc.conf.local.
I think there is some drawback to this solution.
You can only have one daemon running in one rtable at a time
I often run things like sshd in multiple rtables / rdomains in which
case I would have to copy the sshd rc.d script and fiddle a bit here and
there. I would prefer if we would have a rc.conf file specific for a
rtable. Also it is not possible to start daemons with different flags.

Non the less I think this is a move in the right direction.
 
> Index: etc/rc.d/rc.subr
> ===
> RCS file: /cvs/src/etc/rc.d/rc.subr,v
> retrieving revision 1.105
> diff -u -p -r1.105 rc.subr
> --- etc/rc.d/rc.subr  21 Dec 2015 10:18:05 -  1.105
> +++ etc/rc.d/rc.subr  27 Jan 2016 17:57:16 -
> @@ -130,7 +130,7 @@ _rc_parse_conf() {
>   while IFS=' ' read -r _l; do
>   [[ $_l == [!#=]*=* ]] || continue
>   _key=${_l%%*([[:blank:]])=*}
> - [[ $_key == *_@(flags|user|timeout) ]] || \
> + [[ $_key == *_@(flags|rtable|user|timeout) ]] || \
>   [[ " ${_allowed_keys[*]} " == *" $_key "* ]] || 
> \
>   continue
>   [[ $_key == "" ]] && continue
> @@ -154,15 +154,15 @@ rc_start() {
>  }
>  
>  rc_check() {
> - pgrep -q -xf "${pexp}"
> + pgrep -T ${daemon_rtable} -q -xf "${pexp}"
>  }
>  
>  rc_reload() {
> - pkill -HUP -xf "${pexp}"
> + pkill -HUP -T ${daemon_rtable} -xf "${pexp}"
>  }
>  
>  rc_stop() {
> - pkill -xf "${pexp}"
> + pkill -T ${daemon_rtable} -xf "${pexp}"
>  }
>  
>  rc_cmd() {
> @@ -172,6 +172,10 @@ rc_cmd() {
>   [ X"${rc_usercheck}" != X"NO" -a X"$1" = "Xcheck" ] || \
>   _rc_err "$0: need root privileges"
>  
> + if ! route -T ${daemon_rtable} -n show >/dev/null 2>&1; then
> + _rc_err "$0: rtable ${daemon_rtable} does not exist"
> + fi
> + 
>   if _rc_not_supported start || _rc_not_supported stop; then
>   rc_restart=NO
>   fi
> @@ -259,12 +263,14 @@ _RC_RUNFILE=${_RC_RUNDIR}/${_name}
>  _rc_do _rc_parse_conf
>  
>  eval _rcflags=\${${_name}_flags}
> +eval _rcrtable=\${${_name}_rtable}
>  eval _rcuser=\${${_name}_user}
>  eval _rctimeout=\${${_name}_timeout}
>  
>  # set default values; duplicated in rcctl(8)
>  getcap -f /etc/login.conf ${_name} 1>/dev/null 2>&1 && \
>   daemon_class=${_name} || daemon_class=daemon
> +[ -z "${daemon_rtable}" ] && daemon_rtable=0
>  [ -z "${daemon_user}" ] && daemon_user=root
>  [ -z "${daemon_timeout}" ] && daemon_timeout=30
>  
> @@ -273,6 +279,7 @@ getcap -f /etc/login.conf ${_name} 1>/de
>   unset _rcflags
>  
>  [ -n "${_rcflags}" ] && daemon_flags=${_rcflags}
> +[ -n "${_rcrtable}" ] && daemon_rtable=${_rcrtable}
>  [ -n "${_rcuser}" ] && daemon_user=${_rcuser}
>  [ -n "${_rctimeout}" ] && daemon_timeout=${_rctimeout}
>  
> @@ -280,9 +287,13 @@ if [ -n "${_RC_DEBUG}" ]; then
>   echo -n "${_name}_flags "
>   [ -n "${_rcflags}" ] || echo -n "empty, using default "
>   echo ">${daemon_flags}<"
> + echo -n "${_name}_rtable "
> + [ -n "${_rcrtable}" ] || echo -n "empty, using default "
> + echo ">${daemon_rtable}<"   
>  fi
>  
>  readonly daemon_class
> -unset _rcflags _rcuser _rctimeout
> +unset _rcflags _rcrtable _rcuser _rctimeout
>  pexp="${daemon}${daemon_flags:+ ${daemon_flags}}"
> -rcexec="su -l -c ${daemon_class} -s /bin/sh ${daemon_user} -c"
> +rcexec="route -T ${daemon_rtable} exec su -l -c ${daemon_class} -s /bin/sh 
> ${daemon_user} -c"
> +
> Index: usr.sbin/rcctl/rcctl.sh
> ===
> RCS file: /cvs/src/usr.sbin/rcctl/rcctl.sh,v
> retrieving revision 1.88
> diff -u -p -r1.88 rcctl.sh
> --- usr.sbin/rcctl/rcctl.sh   24 Jan 2016 08:51:50 -  1.88
> +++ usr.sbin/rcctl/rcctl.sh   27 Jan 2016 17:57:20 -
> @@ -220,7 +220,7 @@ svc_get()
>   [ -n "${_svc}" ] || return
>  
>   local _status=0 _val _var=$2
> - local daemon_class daemon_flags daemon_timeout daemon_user
> + local daemon_class daemon_flags daemon_rtable daemon_timeout daemon_user
> 

Re: rc.d and rtable

2016-01-27 Thread Jiri B
On Wed, Jan 27, 2016 at 09:30:27PM +0100, Claudio Jeker wrote:
> On Wed, Jan 27, 2016 at 12:58:48PM -0500, Jiri B wrote:
> > On Wed, Jan 27, 2016 at 01:40:14PM +0100, Antoine Jacoutot wrote:
> > > On Wed, Jan 27, 2016 at 06:47:57AM -0500, Jiri B wrote:
> > > > Would it be worth to extend rc.d for rtable knobs?
> > > > 
> > > > - daemon_rtable varible
> > > > - rc_* functions (route exec, pgrep/pkill -T $rtable...)
> > > > 
> > > > Or are routing tables not much used thus not worth to make
> > > > rc.d more complicated?
> > > 
> > > There has been several discussions about this. No decision made though.
> > > If you can find a nice way to implement it, I can have a look.
> > 
> > rc.d framework is so nice... not sure if this is nice way but it
> > works. Maybe check for existing rtable is not great.
> 
> If I see this correctly you add a foo_rtable variable to rc.conf.local.
> I think there is some drawback to this solution.
> You can only have one daemon running in one rtable at a time
> I often run things like sshd in multiple rtables / rdomains in which
> case I would have to copy the sshd rc.d script and fiddle a bit here and
> there. I would prefer if we would have a rc.conf file specific for a
> rtable. Also it is not possible to start daemons with different flags.
> 
> Non the less I think this is a move in the right direction.

Not sure I understand what you meant... Something like this below?

# rcctl ls on | grep httpd
httpd
httpd_rdomain1
# ls -l /etc/rc.d/httpd_rdomain1
lrwxr-xr-x  1 root  wheel  5 Jan 27 17:53 /etc/rc.d/httpd_rdomain1 -> httpd

# rcctl get httpd
httpd_class=daemon
httpd_flags=
httpd_rtable=0
httpd_timeout=30
httpd_user=root
# rcctl get httpd_rdomain1
httpd_rdomain1_class=daemon
httpd_rdomain1_flags=-f /etc/httpd_test.conf
httpd_rdomain1_rtable=1
httpd_rdomain1_timeout=30
httpd_rdomain1_user=root

# rcctl start httpd 
httpd(ok)
# rcctl check httpd 
httpd(ok)
# rcctl start httpd_rdomain1
httpd_rdomain1(ok)
# rcctl check httpd_rdomain1 
httpd_rdomain1(ok)
# ps -axwo pid,rtable,args | grep httpd 
16902  0 httpd: parent (httpd)
29004  0 httpd: logger (httpd)
 4502  0 httpd: server (httpd)
 7467  0 httpd: server (httpd)
26174  0 httpd: server (httpd)
15487  1 httpd: logger (httpd)
24775  1 httpd: server (httpd)
 4002  1 httpd: parent (httpd)
 1225  1 httpd: server (httpd)
22048  1 httpd: server (httpd)
11243  0 grep httpd

j.



Re: rc.d and rtable

2016-01-27 Thread Antoine Jacoutot
> > rc.d framework is so nice... not sure if this is nice way but it
> > works. Maybe check for existing rtable is not great.
> 
> If I see this correctly you add a foo_rtable variable to rc.conf.local.
> I think there is some drawback to this solution.
> You can only have one daemon running in one rtable at a time
> I often run things like sshd in multiple rtables / rdomains in which
> case I would have to copy the sshd rc.d script and fiddle a bit here and

You don't have to copy it, just link it (so you get updates to the original 
script) and add ssht2, ssht3... to pkg_scripts.
But yeah, it's not an obvious road and that's why I warned not to hold any 
breath ;-)

> there. I would prefer if we would have a rc.conf file specific for a
> rtable. Also it is not possible to start daemons with different flags.

Hmm. Can you extend on that?
We should be able to make something like this work:

# ln -s /etc/rc.d/sshd /etc/rc.d/sshdt2
# rcctl enable ssht2
# rcctl set ssht2 flags -f /etc/ssh/wunder_config

> Non the less I think this is a move in the right direction.

It is. It's basically the last obvious situation rc.d does not handle besides 
what was mentioned today (multiple httpd, relayd, ...).
Good thing we have rc.local ;-)

Anyway, I've been pretty busy lately but I think that's something I'd like to 
investigate during our upcoming hackathon a couple months from now (it's too 
late for this release anyway).

-- 
Antoine



Computer hangup : scsi_xfer pool exhausted!

2016-01-27 Thread Sébastien Morand
Hi,

I have a computer hanging up every 4/5 days. It's no more accessible by
network and keyboard is not responding. The only message displayed in
console log is "scsi_xfer pool exhausted!" which is documented by :

/*
 * in this situation we should queue things waiting for an
 * xs and then give them xses when they were supposed be to
 * returned to the pool.
 */

Not sure what it means? How to prevent?

Thanks for any help,
Sebastien

dmesg :
OpenBSD 5.8 (GENERIC.MP) #1236: Sun Aug 16 02:31:04 MDT 2015
dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
real mem = 2031185920 (1937MB)
avail mem = 1965793280 (1874MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.6 @ 0xeb170 (45 entries)
bios0: vendor AMI version "7.15" date 02/14/2012
bios0: Hewlett-Packard HP Pro 3400 Series MT
acpi0 at bios0: rev 2
acpi0: sleep states S0 S1 S3 S4 S5
acpi0: tables DSDT FACP APIC SSDT MCFG SLIC HPET DBGP SSDT
acpi0: wakeup devices PS2K(S3) PS2M(S3) BR20(S3) PEX0(S4) PEX1(S4) PEX2(S4)
PEX3(S4) PEX4(S4) PEX5(S4) RTLK(S4) PEX6(S4) PEX7(S4) P0P1(S4) P0P2(S4)
P0P3(S4) P0P4(S4) [...]
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel(R) Core(TM) i5-2400 CPU @ 3.10GHz, 3093.47 MHz
cpu0:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS
H,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX
,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,A
ES,XSAVE,AVX,LONG,LAHF,PERF,ITSC,SENSOR,ARAT
cpu0: 256KB 64b/line 8-way L2 cache
cpu0: smt 0, core 0, package 0
mtrr: Pentium Pro MTRR support, 10 var ranges, 88 fixed ranges
cpu0: apic clock running at 99MHz
cpu0: mwait min=64, max=64, C-substates=0.2.1.1, IBE
cpu1 at mainbus0: apid 2 (application processor)
cpu1: Intel(R) Core(TM) i5-2400 CPU @ 3.10GHz, 3092.97 MHz
cpu1:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS
H,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX
,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,A
ES,XSAVE,AVX,LONG,LAHF,PERF,ITSC,SENSOR,ARAT
cpu1: 256KB 64b/line 8-way L2 cache
cpu1: smt 0, core 1, package 0
cpu2 at mainbus0: apid 4 (application processor)
cpu2: Intel(R) Core(TM) i5-2400 CPU @ 3.10GHz, 3092.97 MHz
cpu2:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS
H,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX
,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,A
ES,XSAVE,AVX,LONG,LAHF,PERF,ITSC,SENSOR,ARAT
cpu2: 256KB 64b/line 8-way L2 cache
cpu2: smt 0, core 2, package 0
cpu3 at mainbus0: apid 6 (application processor)
cpu3: Intel(R) Core(TM) i5-2400 CPU @ 3.10GHz, 3092.97 MHz
cpu3:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS
H,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX
,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,A
ES,XSAVE,AVX,LONG,LAHF,PERF,ITSC,SENSOR,ARAT
cpu3: 256KB 64b/line 8-way L2 cache
cpu3: smt 0, core 3, package 0
ioapic0 at mainbus0: apid 0 pa 0xfec0, version 20, 24 pins
acpimcfg0 at acpi0 addr 0xe000, bus 0-255
acpihpet0 at acpi0: 14318179 Hz
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus -1 (BR20)
acpiprt2 at acpi0: bus 2 (PEX0)
acpiprt3 at acpi0: bus 3 (PEX1)
acpiprt4 at acpi0: bus 4 (PEX2)
acpiprt5 at acpi0: bus 5 (PEX3)
acpiprt6 at acpi0: bus 6 (PEX4)
acpiprt7 at acpi0: bus 7 (PEX5)
acpiprt8 at acpi0: bus -1 (PEX6)
acpiprt9 at acpi0: bus -1 (PEX7)
acpiprt10 at acpi0: bus 1 (P0P1)
acpiprt11 at acpi0: bus -1 (P0P2)
acpiprt12 at acpi0: bus -1 (P0P3)
acpiprt13 at acpi0: bus -1 (P0P4)
acpicpu0 at acpi0 0x80097b08 cnt:01 stk:00 package: 06
 0x80096888 cnt:01 stk:00 integer: 6
 0x80096e88 cnt:01 stk:00 integer: 0
 0x80096f08 cnt:01 stk:00 integer: 0
 0x80096908 cnt:01 stk:00 integer: fe
 0x80097088 cnt:01 stk:00 integer: 1
 0x80095188 cnt:01 stk:00 integer: 2

CSD r=0 d=0 c=fe n=1 i=2
: C3(350@104 mwait.3@0x20), C3(500@80 mwait.3@0x10), C1(1000@1 mwait.1), PSS
acpicpu1 at acpi0 0x800a0d88 cnt:01 stk:00 package: 06
 0x800a0c08 cnt:01 stk:00 integer: 6
 0x80096e88 cnt:01 stk:00 integer: 0
 0x800a0888 cnt:01 stk:00 integer: 1
 0x800a0908 cnt:01 stk:00 integer: fe
 0x800a0988 cnt:01 stk:00 integer: 1
 0x800a0a08 cnt:01 stk:00 integer: 2

CSD r=0 d=1 c=fe n=1 i=2
: C3(350@104 mwait.3@0x20), C3(500@80 mwait.3@0x10), C1(1000@1 mwait.1), PSS
acpicpu2 at acpi0 0x800a0908 cnt:01 stk:00 package: 06
 0x800a0c08 cnt:01 stk:00 integer: 6
 0x80097a88 cnt:01 stk:00 integer: 0
 0x800a0e08 cnt:01 stk:00 integer: 2
 0x800a0e88 cnt:01 stk:00 integer: fe
 0x800a0f08 cnt:01 stk:00 integer: 1
 

Re: can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Reyk Floeter
On Wed, Jan 27, 2016 at 06:12:22AM -0500, Jiri B wrote:
> Hi,
> 
> I can't run multiple instances of httpd via rc.d as I can't distinguish
> between httpd instances. ps aux never show flags passed to httpd.
> 
> Could httpd be extended to show flags like sshd does it?
> 
> root 15681  0.0  0.1  1196  2308 ??  Ssp   12:08PM0:00.05 httpd: 
> parent (httpd)
> 
> vs
> 
> root 17247  0.0  0.1   920  1376 ??  Ss12:09PM0:00.03 
> /usr/sbin/sshd -f /etc/ssh/test_sshd_config
> 
> Or is there any other way to distinguish between two httpd instances?
> 
> j.
> 

Interesting point, I never thought about it.

Reyk



can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Jiri B
Hi,

I can't run multiple instances of httpd via rc.d as I can't distinguish
between httpd instances. ps aux never show flags passed to httpd.

Could httpd be extended to show flags like sshd does it?

root 15681  0.0  0.1  1196  2308 ??  Ssp   12:08PM0:00.05 httpd: parent 
(httpd)

vs

root 17247  0.0  0.1   920  1376 ??  Ss12:09PM0:00.03 
/usr/sbin/sshd -f /etc/ssh/test_sshd_config

Or is there any other way to distinguish between two httpd instances?

j.



Re: can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Kamil Cholewiński
> Or is there any other way to distinguish between two httpd instances?

Try runit: http://smarden.org/runit/



rc.d and rtable

2016-01-27 Thread Jiri B
Would it be worth to extend rc.d for rtable knobs?

- daemon_rtable varible
- rc_* functions (route exec, pgrep/pkill -T $rtable...)

Or are routing tables not much used thus not worth to make
rc.d more complicated?

j.



Re: GitLab on OpenBSD

2016-01-27 Thread Oriol Demaria
I do run Gitlab on OpenBSD stable, so I'm still with 8.1, as further
need go 1.5 and it's not there. Also I use PostgreSQL as DB.

There are a few things that you need to do:

* git home user directory in /var/www/git, as web server is chrooted
* git user needs bash as shell
* in the bundle operation in the --without statement add always
as it won't compile if it's there.
* comment out shell_path from the init script
* put the correct path of the shell for scripts bin/web and
bin/background_jobs

If you have experience with web servers and so on you should be able to
configure the rest.

Regards,

Stefan Kempf  writes:

> Predrag Punosevac wrote:
>> Hi Misc,
>> 
>> A question for Ruby gurus among OpenBSD users. Is it possible to run
>> GitLab on OpenBSD? I see some reports of people running GitLab on
>> FreeBSD
>
> Not a ruby guru, but yes it can be done in principle. However, I just
> gave it a quick try and don't use it in production though.
>
> You'll have to do the manual setup though. These are the instructions I
> used:
>
> https://gitlab.com/gitlab-org/gitlab-ce/blob/8-1-stable/doc/install/installation.md
>
> All required packages should be in ports. For sidekiq, you might this
> fix: 
> https://github.com/mperham/sidekiq/commit/a6ea55d16fb0060b8ee0a322bede1951cff51fba
>
> And you may need to tweak the syntax in the gitlab
> lib/support/init.d/gitlab/gitlab shellscript (and the scripts is calls)
> or change it to use bash.
>
>> https://github.com/gitlabhq/gitlab-recipes/blob/master/install/freebsd/freebsd-10.md
>> 
>> 
>> Best,
>> Predrag

-- 
Oriol Demaria
0x58415679



Re: rc.d and rtable

2016-01-27 Thread Antoine Jacoutot
On Wed, Jan 27, 2016 at 06:47:57AM -0500, Jiri B wrote:
> Would it be worth to extend rc.d for rtable knobs?
> 
> - daemon_rtable varible
> - rc_* functions (route exec, pgrep/pkill -T $rtable...)
> 
> Or are routing tables not much used thus not worth to make
> rc.d more complicated?

There has been several discussions about this. No decision made though.
If you can find a nice way to implement it, I can have a look.

-- 
Antoine



Re: can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Antoine Jacoutot
On Wed, Jan 27, 2016 at 12:30:08PM +0100, Reyk Floeter wrote:
> On Wed, Jan 27, 2016 at 06:12:22AM -0500, Jiri B wrote:
> > Hi,
> > 
> > I can't run multiple instances of httpd via rc.d as I can't distinguish
> > between httpd instances. ps aux never show flags passed to httpd.
> > 
> > Could httpd be extended to show flags like sshd does it?
> > 
> > root 15681  0.0  0.1  1196  2308 ??  Ssp   12:08PM0:00.05 httpd: 
> > parent (httpd)
> > 
> > vs
> > 
> > root 17247  0.0  0.1   920  1376 ??  Ss12:09PM0:00.03 
> > /usr/sbin/sshd -f /etc/ssh/test_sshd_config
> > 
> > Or is there any other way to distinguish between two httpd instances?
> > 
> > j.
> > 
> 
> Interesting point, I never thought about it.

That's not httpd specific. Most of our privilege separated daemons do that and 
it sucks :-)

-- 
Antoine



Re: can't run multiple instances of httpd, flags not visible in processes

2016-01-27 Thread Aner Perez

On 01/27/2016 06:12 AM, Jiri B wrote:

Hi,

I can't run multiple instances of httpd via rc.d as I can't distinguish
between httpd instances. ps aux never show flags passed to httpd.

Could httpd be extended to show flags like sshd does it?

root 15681  0.0  0.1  1196  2308 ??  Ssp   12:08PM0:00.05 httpd: parent 
(httpd)

vs

root 17247  0.0  0.1   920  1376 ??  Ss12:09PM0:00.03 
/usr/sbin/sshd -f /etc/ssh/test_sshd_config

Or is there any other way to distinguish between two httpd instances?

j.



You could always run fstat(1) on the pid to see which ports it has open.

- Aner