[PATCH] Add IPV6_RECVDSTPORT socket option
Hello, I have added IPV6_RECVDSTPORT socket option, which enables us to get original (= before divert) destination port of a UDP packet. The way to use this option is same as IP_RECVDSTPORT. The values of IPV6_RECVDSTPORT and IN6P_RECVDSTPORT are temporary. UMEZAWA Takeshi (FAMILY Given) umez...@iij.ad.jp Internet Initiative Japan Inc. diff --git a/share/man/man4/ip6.4 b/share/man/man4/ip6.4 index dc54d77..0090b85 100644 --- a/share/man/man4/ip6.4 +++ b/share/man/man4/ip6.4 @@ -421,6 +421,16 @@ Get or set the ESP encapsulation level. Get or set the .Xr ipcomp 4 level. +.It Dv IPV6_RECVDSTPORT Fa int * +Get or set the status of whether the destination port for a UDP datagram +will be provided as ancillary data along with the payload in subsequent +.Xr recvmsg 2 +calls. The information is stored as a single value of type +.Vt u_int16_t +in network byte order. +.Pp +Turning this option on will result in this socket getting cmsg data of +type IPV6_RECVDSTPORT. .El .Pp The diff --git a/sys/netinet/in_pcb.h b/sys/netinet/in_pcb.h index 9d4f0d9..def52de 100644 --- a/sys/netinet/in_pcb.h +++ b/sys/netinet/in_pcb.h @@ -196,6 +196,7 @@ struct inpcbtable { */ #define IN6P_HIGHPORT INP_HIGHPORT/* user wants high port */ #define IN6P_LOWPORT INP_LOWPORT /* user wants low port */ +#define IN6P_RECVDSTPORT INP_RECVDSTPORT /* receive IP dst addr before rdr */ #define IN6P_PKTINFO 0x01 /* receive IP6 dst and I/F */ #define IN6P_HOPLIMIT 0x02 /* receive hoplimit */ #define IN6P_HOPOPTS 0x04 /* receive hop-by-hop options */ @@ -215,7 +216,7 @@ struct inpcbtable { #define IN6P_CONTROLOPTS (IN6P_PKTINFO|IN6P_HOPLIMIT|IN6P_HOPOPTS|\ IN6P_DSTOPTS|IN6P_RTHDR|IN6P_RTHDRDSTOPTS|\ IN6P_TCLASS|IN6P_AUTOFLOWLABEL|IN6P_RFC2292|\ -IN6P_MTU) +IN6P_MTU|IN6P_RECVDSTPORT) #endif #defineINPLOOKUP_WILDCARD 1 diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c index 5a8d8e5..44c3472 100644 --- a/sys/netinet/udp_usrreq.c +++ b/sys/netinet/udp_usrreq.c @@ -688,6 +688,16 @@ udp_input(struct mbuf *m, ...) if (ip (inp-inp_flags INP_CONTROLOPTS || inp-inp_socket-so_options SO_TIMESTAMP)) ip_savecontrol(inp, opts, ip, m); +#ifdef INET6 + if (ip6 (inp-inp_flags IN6P_RECVDSTPORT)) { + struct mbuf **mp = opts; + + while (*mp) + mp = (*mp)-m_next; + *mp = sbcreatecontrol((caddr_t)uh-uh_dport, sizeof(u_int16_t), + IPV6_RECVDSTPORT, IPPROTO_IPV6); + } +#endif /* INET6 */ if (ip (inp-inp_flags INP_RECVDSTPORT)) { struct mbuf **mp = opts; diff --git a/sys/netinet6/in6.h b/sys/netinet6/in6.h index 664bca9..395ef9d 100644 --- a/sys/netinet6/in6.h +++ b/sys/netinet6/in6.h @@ -451,6 +451,8 @@ struct route_in6 { #define IPV6_DONTFRAG 62 /* bool; disable IPv6 fragmentation */ #define IPV6_PIPEX 63 /* bool; using PIPEX */ +#define IPV6_RECVDSTPORT 64 /* bool; receive IP dst port w/dgram */ + #define IPV6_RTABLE0x1021 /* int; routing table, see SO_RTABLE */ /* to define items, should talk with KAME guys first, for *BSD compatibility */ diff --git a/sys/netinet6/ip6_output.c b/sys/netinet6/ip6_output.c index 07aedee..d4a371d 100644 --- a/sys/netinet6/ip6_output.c +++ b/sys/netinet6/ip6_output.c @@ -1356,6 +1356,7 @@ ip6_ctloutput(int op, struct socket *so, int level, int optname, case IPV6_RECVTCLASS: case IPV6_V6ONLY: case IPV6_AUTOFLOWLABEL: + case IPV6_RECVDSTPORT: if (m == NULL || m-m_len != sizeof(int)) { error = EINVAL; break; @@ -1504,6 +1505,9 @@ do { \ OPTSET(IN6P_AUTOFLOWLABEL); break; + case IPV6_RECVDSTPORT: + OPTSET(IN6P_RECVDSTPORT); + break; } break; @@ -1766,6 +1770,7 @@ do { \ case IPV6_PORTRANGE: case IPV6_RECVTCLASS: case IPV6_AUTOFLOWLABEL: + case IPV6_RECVDSTPORT: switch (optname) { case IPV6_RECVHOPOPTS: @@ -1827,6 +1832,10 @@ do { \ case IPV6_AUTOFLOWLABEL: optval = OPTBIT(IN6P_AUTOFLOWLABEL);
Re: Use ACPI to detect secondary PCI root segments on x86
Hi again, On Thu, Sep 06, 2012 at 11:24:01AM +0200, Christian Ehrhardt wrote: most modern x86 hardware includes more than one PCI root segement. E.g. a hardware that I have here has four PCI root segemnts with bus numbers 0, 0x7f, 0x80 and 0xff respectively. (0x7f and 0xff host the uncore devices of each processor). These segments are already detected by APCI but this information is not used when attaching PCI busses to the mainbus. Below is a patch that should solve the PCI bus detection problem in a robust way. Below is a diff of the dmesg output before and after the patch. Comments welcome. regardsChristian --- dmesg.before2012-09-07 10:06:49.0 +0200 +++ dmesg.after 2012-09-07 10:10:21.0 +0200 @@ -1,186 +1,300 @@ Copyright (c) 1982, 1986, 1989, 1991, 1993 The Regents of the University of California. All rights reserved. Copyright (c) 1995-2012 OpenBSD. All rights reserved. http://www.OpenBSD.org OpenBSD 5.2-current (GENERIC.MP) ... cpu0: Intel(R) Xeon(R) CPU E5-2667 0 @ 2.90GHz (GenuineIntel 686-class) 2.91 GHz cpu0: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,LONG,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,LAHF real mem = 2118721536 (2020MB) avail mem = 2073182208 (1977MB) mainbus0 at root bios0 at mainbus0: AT/286+ BIOS, date 10/11/11, SMBIOS rev. 2.7 @ 0xeb2f0 (65 entries) bios0: vendor American Megatrends Inc. version 1.0a date 06/05/2012 bios0: Supermicro X9DRH-7TF/7F/iTF/iF acpi0 at bios0: rev 2 acpi0: sleep states S0 S1 S4 S5 acpi0: tables DSDT FACP APIC MCFG PRAD SRAT SLIT HPET SPMI SSDT SPCR BGRT DMAR acpi0: wakeup devices BR20(S1) EUSB(S4) USBE(S4) NPE1(S4) NPE2(S4) NPE3(S4) NPE4(S4) NPE5(S4) NPE6(S4) NPE7(S4) NPE8(S4) NPE9(S4) I35P(S4) I35I(S4) X54P(S4) X54I(S4) NPEA(S4) SLPB(S0) NPE1(S4) NPE2(S4) NPE3(S4) NPE4(S4) NPE5(S4) NPE6(S4) NPE7(S4) NPE8(S4) NPE9(S4) NPEA(S4) acpitimer0 at acpi0: 3579545 Hz, 24 bits acpimadt0 at acpi0 addr 0xfee0: PC-AT compat cpu0 at mainbus0: apid 0 (boot processor) cpu0: apic clock running at 100MHz cpu1 at mainbus0: apid 2 (application processor) cpu1: Intel(R) Xeon(R) CPU E5-2667 0 @ 2.90GHz (GenuineIntel 686-class) 2.91 GHz cpu1: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,LONG,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,LAHF cpu2 at mainbus0: apid 4 (application processor) cpu2: Intel(R) Xeon(R) CPU E5-2667 0 @ 2.90GHz (GenuineIntel 686-class) 2.91 GHz cpu2: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,LONG,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,LAHF cpu3 at mainbus0: apid 6 (application processor) cpu3: Intel(R) Xeon(R) CPU E5-2667 0 @ 2.90GHz (GenuineIntel 686-class) 2.91 GHz cpu3: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,LONG,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,LAHF cpu4 at mainbus0: apid 8 (application processor) cpu4: Intel(R) Xeon(R) CPU E5-2667 0 @ 2.90GHz (GenuineIntel 686-class) 2.91 GHz cpu4: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,LONG,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,LAHF cpu5 at mainbus0: apid 10 (application processor) cpu5: Intel(R) Xeon(R) CPU E5-2667 0 @ 2.90GHz (GenuineIntel 686-class) 2.91 GHz cpu5: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,LONG,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,LAHF cpu6 at mainbus0: apid 32 (application processor) cpu6: Intel(R) Xeon(R) CPU E5-2667 0 @ 2.90GHz (GenuineIntel 686-class) 2.91 GHz cpu6: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,LONG,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,DCA,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,AES,XSAVE,AVX,LAHF cpu7 at mainbus0: apid 34 (application processor) cpu7: Intel(R) Xeon(R) CPU E5-2667 0 @ 2.90GHz (GenuineIntel 686-class) 2.91 GHz cpu7:
Re: use time_uptime for various pf expirations
On 22.8.2012. 20:50, Florian Obser wrote: Hi, I think I got this now. - replace time_seconds with time_uptime - with that flow_finish in pflow can be simplified (pointed out by benno@) this should take care of flows with finish start for localy created states - change various variables from unsigned to signed (mainly) in pfsync which could underflow (inspired by a patch from dlg@ from last year, pointed out by cameild@). This fixes pflow and at the same time an underflow problem in pfsync which dlg's patch was addressing. If I understand the history correctly cameild@ noticed this problem last year. Hrvoje Popovski tested an older version without the pfsync fix. Since this changes the semantics of a field in pfsync both pfsync machines need to be updated (I think it's ok to import 5.1 states into this version but the other way around will cause problems.) We are running with this patch since yesterday on a redundant firewall (amd64) with pfsync and no longer see broken flows (i.e. where finish start). The pair survived various failovers. Index: share/man/man4/pflow.4 === RCS file: /opt/OpenBSD-CVS/src/share/man/man4/pflow.4,v retrieving revision 1.11 diff -u -p -u -r1.11 pflow.4 --- share/man/man4/pflow.42 Feb 2012 12:34:37 - 1.11 +++ share/man/man4/pflow.422 Aug 2012 18:20:08 - @@ -127,6 +127,12 @@ The device first appeared in .Ox 4.5 . .Sh BUGS +A state created by +.Xr pfsync 4 +can have a creation or expiration time before the machine came up. +.Nm +pretends the flow was created or expired when the machine came up. + The IPFIX implementation is incomplete: The required transport protocol SCTP is not supported. Transport over TCP and DTLS protected flow export is also not supported. Index: sys/net/if_pflow.c === RCS file: /opt/OpenBSD-CVS/src/sys/net/if_pflow.c,v retrieving revision 1.20 diff -u -p -u -r1.20 if_pflow.c --- sys/net/if_pflow.c11 Apr 2012 17:42:53 - 1.20 +++ sys/net/if_pflow.c22 Aug 2012 18:20:08 - @@ -553,12 +553,15 @@ copy_flow_data(struct pflow_flow *flow1, flow1-flow_octets = htonl(st-bytes[0]); flow2-flow_octets = htonl(st-bytes[1]); - flow1-flow_start = flow2-flow_start = + /* + * Pretend the flow was created or expired when this machine + * came up when the state's creation or expiration is in the past. + */ + flow1-flow_start = flow2-flow_start = st-creation 0 ? 0 : htonl(st-creation * 1000); - flow1-flow_finish = flow2-flow_finish = - htonl((time_uptime - (st-rule.ptr-timeout[st-timeout] ? - st-rule.ptr-timeout[st-timeout] : - pf_default_rule.timeout[st-timeout])) * 1000); + flow1-flow_finish = flow2-flow_finish = st-expire 0 ? 0 : + htonl(st-expire * 1000); + flow1-tcp_flags = flow2-tcp_flags = 0; flow1-protocol = flow2-protocol = sk-proto; flow1-tos = flow2-tos = st-rule.ptr-tos; @@ -580,12 +583,14 @@ copy_flow4_data(struct pflow_flow4 *flow flow1-flow_octets = htobe64(st-bytes[0]); flow2-flow_octets = htobe64(st-bytes[1]); - flow1-flow_start = flow2-flow_start = + /* + * Pretend the flow was created or expired when this machine + * came up when the state's creation or expiration is in the past. + */ + flow1-flow_start = flow2-flow_start = st-creation 0 ? 0 : htonl(st-creation * 1000); - flow1-flow_finish = flow2-flow_finish = - htonl((time_uptime - (st-rule.ptr-timeout[st-timeout] ? - st-rule.ptr-timeout[st-timeout] : - pf_default_rule.timeout[st-timeout])) * 1000); + flow1-flow_finish = flow2-flow_finish = st-expire 0 ? 0 : + htonl(st-expire * 1000); flow1-protocol = flow2-protocol = sk-proto; flow1-tos = flow2-tos = st-rule.ptr-tos; @@ -608,12 +613,14 @@ copy_flow6_data(struct pflow_flow6 *flow flow1-flow_octets = htobe64(st-bytes[0]); flow2-flow_octets = htobe64(st-bytes[1]); - flow1-flow_start = flow2-flow_start = + /* + * Pretend the flow was created or expired when this machine + * came up when the state's creation or expiration is in the past. + */ + flow1-flow_start = flow2-flow_start = st-creation 0 ? 0 : htonl(st-creation * 1000); - flow1-flow_finish = flow2-flow_finish = - htonl((time_uptime - (st-rule.ptr-timeout[st-timeout] ? - st-rule.ptr-timeout[st-timeout] : - pf_default_rule.timeout[st-timeout])) * 1000); + flow1-flow_finish = flow2-flow_finish = st-expire 0 ? 0 : + htonl(st-expire * 1000); flow1-protocol = flow2-protocol = sk-proto; flow1-tos = flow2-tos = st-rule.ptr-tos; Index: sys/net/if_pfsync.c
gcc 3 in 5.2?
Don't think so, but I may be wrong. Index: 52.html === RCS file: /home/vcs/cvs/openbsd/www/52.html,v retrieving revision 1.32 diff -u -p -r1.32 52.html --- 52.html 7 Sep 2012 02:27:05 - 1.32 +++ 52.html 7 Sep 2012 11:54:16 - @@ -361,7 +361,7 @@ the package build process: liXenocara (based on X.Org 7.7 with xserver 1.12.2 + patches, freetype 2.4.10, fontconfig 2.8.0, Mesa 7.10.3, xterm 279, xkeyboard-config 2.6 and more) -liGcc 4.2.1 (+patches), 3.3.5 (+ patches) and 2.95.3 (+ patches) +liGcc 4.2.1 (+patches) and 2.95.3 (+ patches) liPerl 5.12.2 (+ patches) liOur improved and secured version of Apache 1.3, with SSL/TLS and DSO support
Re: ntpd(8) option to provide time even when not being synced
Could I ask what your use-case is? -E On Fri, Aug 24, 2012 at 01:41:21PM +0200, Patrick Wildt wrote: the diff below adds an option to the ntpd(8), which has him provide time, even though he's not synced. ok? Index: ntpd.8 === RCS file: /cvs/src/usr.sbin/ntpd/ntpd.8,v retrieving revision 1.31 diff -u -r1.31 ntpd.8 --- ntpd.817 Sep 2011 10:22:00 - 1.31 +++ ntpd.824 Aug 2012 11:17:17 - @@ -23,7 +23,7 @@ .Sh SYNOPSIS .Nm ntpd .Bk -words -.Op Fl dnSsv +.Op Fl dinSsv .Op Fl f Ar file .Ek .Sh DESCRIPTION @@ -47,6 +47,9 @@ .Nm will run in the foreground and log to .Em stderr . +.It Fl i +Provide time, even though the time is +not synced. .It Fl f Ar file Use .Ar file Index: ntpd.c === RCS file: /cvs/src/usr.sbin/ntpd/ntpd.c,v retrieving revision 1.69 diff -u -r1.69 ntpd.c --- ntpd.c19 Mar 2011 23:40:11 - 1.69 +++ ntpd.c24 Aug 2012 11:17:17 - @@ -73,7 +73,7 @@ { extern char *__progname; - fprintf(stderr, usage: %s [-dnSsv] [-f file]\n, __progname); + fprintf(stderr, usage: %s [-dinSsv] [-f file]\n, __progname); exit(1); } @@ -97,13 +97,16 @@ log_init(1);/* log to stderr until daemonized */ - while ((ch = getopt(argc, argv, df:nsSv)) != -1) { + while ((ch = getopt(argc, argv, df:insSv)) != -1) { switch (ch) { case 'd': lconf.debug = 1; break; case 'f': conffile = optarg; + break; + case 'i': + lconf.ignore_sync = 1; break; case 'n': lconf.noaction = 1; Index: ntpd.h === RCS file: /cvs/src/usr.sbin/ntpd/ntpd.h,v retrieving revision 1.105 diff -u -r1.105 ntpd.h --- ntpd.h21 Sep 2011 16:38:05 - 1.105 +++ ntpd.h24 Aug 2012 11:17:17 - @@ -180,6 +180,7 @@ u_int8_tdebug; u_int8_tnoaction; u_int8_tfilters; + u_int8_tignore_sync; }; enum imsg_type { Index: server.c === RCS file: /cvs/src/usr.sbin/ntpd/server.c,v retrieving revision 1.36 diff -u -r1.36 server.c --- server.c 21 Sep 2011 15:41:30 - 1.36 +++ server.c 24 Aug 2012 11:17:17 - @@ -188,7 +188,7 @@ version = (query.status VERSIONMASK) 3; bzero(reply, sizeof(reply)); - if (lconf-status.synced) + if (lconf-status.synced || lconf-ignore_sync) reply.status = lconf-status.leap; else reply.status = LI_ALARM; @@ -200,7 +200,9 @@ else /* ignore packets of different type (e.g. bcast) */ return (0); - reply.stratum = lconf-status.stratum; + /* set stratum to 10 when we're not synced but still provide time */ + reply.stratum = (lconf-status.synced || !lconf-ignore_sync) ? + lconf-status.stratum : 10; reply.ppoll = query.ppoll; reply.precision = lconf-status.precision; reply.rectime = d_to_lfp(rectime);
Re: ntpd(8) option to provide time even when not being synced
I have machines which might not have an internet connection, but still need to be synchronized, even if the time's not correct. What's important is, that every machine in the network has the same time. Also the ntp server doesn't have a sensor to synchronize to. Patrick Am 07.09.2012 um 17:33 schrieb Eric P. Mangold e...@teratorn.org: Could I ask what your use-case is? -E On Fri, Aug 24, 2012 at 01:41:21PM +0200, Patrick Wildt wrote: the diff below adds an option to the ntpd(8), which has him provide time, even though he's not synced. ok? Index: ntpd.8 === RCS file: /cvs/src/usr.sbin/ntpd/ntpd.8,v retrieving revision 1.31 diff -u -r1.31 ntpd.8 --- ntpd.8 17 Sep 2011 10:22:00 - 1.31 +++ ntpd.8 24 Aug 2012 11:17:17 - @@ -23,7 +23,7 @@ .Sh SYNOPSIS .Nm ntpd .Bk -words -.Op Fl dnSsv +.Op Fl dinSsv .Op Fl f Ar file .Ek .Sh DESCRIPTION @@ -47,6 +47,9 @@ .Nm will run in the foreground and log to .Em stderr . +.It Fl i +Provide time, even though the time is +not synced. .It Fl f Ar file Use .Ar file Index: ntpd.c === RCS file: /cvs/src/usr.sbin/ntpd/ntpd.c,v retrieving revision 1.69 diff -u -r1.69 ntpd.c --- ntpd.c 19 Mar 2011 23:40:11 - 1.69 +++ ntpd.c 24 Aug 2012 11:17:17 - @@ -73,7 +73,7 @@ { extern char *__progname; -fprintf(stderr, usage: %s [-dnSsv] [-f file]\n, __progname); +fprintf(stderr, usage: %s [-dinSsv] [-f file]\n, __progname); exit(1); } @@ -97,13 +97,16 @@ log_init(1);/* log to stderr until daemonized */ -while ((ch = getopt(argc, argv, df:nsSv)) != -1) { +while ((ch = getopt(argc, argv, df:insSv)) != -1) { switch (ch) { case 'd': lconf.debug = 1; break; case 'f': conffile = optarg; +break; +case 'i': +lconf.ignore_sync = 1; break; case 'n': lconf.noaction = 1; Index: ntpd.h === RCS file: /cvs/src/usr.sbin/ntpd/ntpd.h,v retrieving revision 1.105 diff -u -r1.105 ntpd.h --- ntpd.h 21 Sep 2011 16:38:05 - 1.105 +++ ntpd.h 24 Aug 2012 11:17:17 - @@ -180,6 +180,7 @@ u_int8_tdebug; u_int8_tnoaction; u_int8_tfilters; +u_int8_tignore_sync; }; enum imsg_type { Index: server.c === RCS file: /cvs/src/usr.sbin/ntpd/server.c,v retrieving revision 1.36 diff -u -r1.36 server.c --- server.c 21 Sep 2011 15:41:30 - 1.36 +++ server.c 24 Aug 2012 11:17:17 - @@ -188,7 +188,7 @@ version = (query.status VERSIONMASK) 3; bzero(reply, sizeof(reply)); -if (lconf-status.synced) +if (lconf-status.synced || lconf-ignore_sync) reply.status = lconf-status.leap; else reply.status = LI_ALARM; @@ -200,7 +200,9 @@ else /* ignore packets of different type (e.g. bcast) */ return (0); -reply.stratum = lconf-status.stratum; +/* set stratum to 10 when we're not synced but still provide time */ +reply.stratum = (lconf-status.synced || !lconf-ignore_sync) ? +lconf-status.stratum : 10; reply.ppoll = query.ppoll; reply.precision = lconf-status.precision; reply.rectime = d_to_lfp(rectime);
Cómo Ser un Gran Negociador
Cómo Ser un Gran Negociador SEMINARIO ONLINE EN VIVO este 18 de Septiembre de 2012. Negociar es estresante, usted sabe ahora que eso requiere de ceder y mantenerse firme, pero ¿Cuándo debería ceder y cuándo debería ser firme? La única diferencia entre aquellos que están seguros de su habilidad para lograr grandes tratos y aquellos que no, es que los negociadores más fuertes han dominado LOS SECRETOS PARA MANTENERSE FIRMES en obtener los acuerdos que ellos quieren. ¡Usted puede aprender a ser un negociador fuerte sin dejar de ser justo!. Usted aprenderá las técnicas exitosas para obtener lo que quiere, cuándo presionar a un adversario y cuándo ceder un poco, cómo desarrollar ese valioso escudo para desviar las emociones del otro mientras mantiene la atención en las suyas ¡Y mucho más! Usted conocerá aspectos relevantes incluyendo: Blindaje invisible- La estrategia maestra que podrá utilizar en contra de las amenazas de adversarios, de las contraofertas y de las justificaciones Cómo detectar una actitud honesta o falsa de su adversario Cómo crear las armas secretas que le darán la posición que usted quiere Cómo evitar ser arrinconado en la negociación y qué puede hacer al respecto Las tácticas que usan los mejores negociadores para debilitar a un oponente 3 recomendaciones de tiempo para saber cuándo ejercer presión, cuándo ceder y cuándo mantenerse firme Cómo mantener las emociones bajo control, después de una prolongada negociación Cómo estar seguro que no está presionando demasiado a su adversario, al punto de que pueda poner en riesgo el trato y qué hacer si accidentalmente esto sucede. Adquiera la información completa y sin compromiso, solo responda este correo con asunto -Deseo Folleto Negociador o Comuníquese al (507) 279-1083 / 279-0258 / 279-0887 - y a la brevedad lo recibirá! ESTE CORREO NO PUEDE SER CONSIDERADO INTRUSIVO YA QUE CUMPLE CON LAS POLÍTICAS ANTISPAM INTERNACIONALES Y LOCALES: Responda este correo con el Asunto borrar y automáticamente quedará fuera de nuestras listas. Este correo ha sido enviado a: tech@openbsd.org
Re: ntpd(8) option to provide time even when not being synced
On 9/7/2012 at 6:35 PM Patrick Wildt wrote: |I have machines which might not have an internet connection, but still |need to |be synchronized, |even if the time's not correct. What's important is, that every machine in |the |network has the |same time. Also the ntp server doesn't have a sensor to synchronize to. === Comments in the context of RFC5905... Instead of sending out stratum 10, it may be better to send out stratum 16 per the RFC, indicating the clock is unsynchronized. You are effectively sync'ing to the local clock. What will you be sending out for the reference ID to the clients that sync up to the server? I would suggest either 127.0.0.1, formatted appropriately, or you might use the four characters XLCL to indicate you are using the LoCaL clock.
Sobre mis pasiones vino y música, invitación a presentación de Camalotal: Mariano Toscano
MARIANO TOSCANO Presenta su disco... CAMALOTAL Recientemente editado por Epsa Music. Atmosfera Funk y Groove, incluyendo ritmos de Rock, Milonga, Baladas fusionado a los aires litoraleños. El músico y la musica se retroalimentan constantemente para dar como resultado esta original propuesta de colores y sensaciones tan calidas ? Canciones de alto vuelo!!! Mariano Toscano (Voz y guitarras) MartÃn Yubro (Guitarra eléctrica) Julia SubatÃn (Bajo eléctrico) Anibal Guevara (BaterÃa y percusión) INVITADOS DE LUJO YACARE MANSO Este viernes 7 de Septiembre a la medianoche en CAFà VINILO Gorriti 3780 - Palermo. Consultas y Reservas : 011 4866-6510 i...@cafevinilo.com.ar www.cafevinilo.com.ar ENTRADAS GENERALES $ 40 ANTICIPADAS CON DESCUENTO EN BOLETERIA $35 PROMO DE AMOR $30 c/u si venÃs con tu pareja el viernes DISCOS A PRECIOS PROMOCIONALES POR LANZAMIENTO!!! y próximamente en disquerÃas. Camalotal comprende una novedosa búsqueda sonora que es esencial escenografÃa de los versos más sinceros. El camino surge de la nada. Sonido que viene del silencio y al silencio va. La canción llega, hace lo suyo y despierta para siempre: sin parpadear, como el ojo del sol. Camalotal que viaja en la corriente, torbellino, electricidad, conexión, rÃo, rÃes, mástil sin bandera, adoquÃn y naranjos: esquinas donde el cuerpo se vuelve canción, donde la vida se vuelve canción y la canción se vuelve vida. Camalote viajando. Las raÃces del camalote enraizadas en el viaje, la melodÃa. Inventa el viento, lo silba, el agua, la tierra, y el fuego prende a todo color. Algo te estremece sin sentido. VenÃ, viajá: Gira, gira, gira que me vas a enloquecer. âEn lo que hacerâ de la canción: la danza del colchón, un mundo, camalotal de amor. Camalotal hecho canción.â Esteban Bértola. Editores Argentinos. ¡No te lo pierdas! Si no podés visualizar el flyer correctamente, hacé click aquà [IMAGE] Mariano Toscano www.marianotoscano.com.ar Móv il 15-6382-7141 ID 176*1021 ## Hace click acá, y escucha el corte de difusión de CAMALOTAL. http://www .myspace.com/music/player?sid=88690289ac=now ## si queres conocer más podes ingresar: a su myspace : http://www.myspace.com/marianoto scano ó también a su Facebook : https://www.facebook.com/camalotal /a ó a su web que aún esta en construcción... pero algo tenes para escuchar AQUà :www.marianotoscano.com.ar Te esperamos este viernes 7 de Septiembre a la medianoche . venà a disfrutar ! Todo el Groove, funk, rock, milongón, reggae, balada, unidos por la canción generando una nueva propuesta sonora para los versos mas sinceros e inspirados. Escucharás las canciones del flamante disco CAMALOTAL recientemente editado por el notable sello discográfico EPSA MUSIC