330449 |
05-Mar-2018 |
eadler |
MFC r326276:
various: general adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone - task.
The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts.
No functional change intended. |
330332 |
03-Mar-2018 |
eadler |
MFC r307519,r307629:
Increase timeout so low-end platforms have a chance to complete test procedures.
This fixes operation in QEMU/MIPS64. |
330324 |
03-Mar-2018 |
eadler |
MFC r322210,r322613,r322831:
pgrep naively appends the delimiter to all PIDs including the last e.g. "pgrep -d, getty" outputs "1399,1386,1309,1308,1307,1306,1305,1302," Ensure the list is correctly delimited by suppressing the emission of the delimiter after the final PID.
The r322210 change to pgrep's PID delimiting behaviour causes pgrep's default output to not include a trailing new line, which is a potential POLA violation for existing consumers. Change pgrep to always emit a trailing new line on completion of its output, regardless of the delimeter in use (which technically is also a potential POLA violation for existing consumers that rely on the pre-r322210 buggy behaviour, but a line has to be drawn somewhere).
Only emit the trailing new line added in r322613 when not operating in quiet mode.
PR: 221534 (r322613) |
330319 |
03-Mar-2018 |
eadler |
MFC r319602:
Clarify -q is only for pgrep. |
319016 |
28-May-2017 |
rgrimes |
MFC r314833 Convert absolute links to relative links. Style.Makefile(9) has been ignored to produce minimal diffs.
MFC r314837 The relative symlink fix causes downstream issues for EMC DELL Isilon so revert the relative symlink fix pending a better solution.
Reported by: ngie
MFC r315091 Revert r314833 until the problem with INSTALL_RSYMLINKS can be found as it appears to break arm release builds.
PR: 217705 Reported by: cyclaero@gmail.com
Approved by: grehan (mentor) |
302408 |
08-Jul-2016 |
gjb |
Copy head@r302406 to stable/11 as part of the 11.0-RELEASE cycle. Prune svn:mergeinfo from the new branch, as nothing has been merged here.
Additional commits post-branch will follow.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
299094 |
04-May-2016 |
ngie |
Merge ^/user/ngie/release-pkg-fix-tests to unbreak how test files are installed after r298107
Summary of changes:
- Replace all instances of FILES/TESTS with ${PACKAGE}FILES. This ensures that namespacing is kept with FILES appropriately, and that this shouldn't need to be repeated if the namespace changes -- only the definition of PACKAGE needs to be changed - Allow PACKAGE to be overridden by callers instead of forcing it to always be `tests`. In the event we get to the point where things can be split up enough in the base system, it would make more sense to group the tests with the blocks they're a part of, e.g. byacc with byacc-tests, etc - Remove PACKAGE definitions where possible, i.e. where FILES wasn't used previously. - Remove unnecessary TESTSPACKAGE definitions; this has been elided into bsd.tests.mk - Remove unnecessary BINDIRs used previously with ${PACKAGE}FILES; ${PACKAGE}FILESDIR is now automatically defined in bsd.test.mk. - Fix installation of files under data/ subdirectories in lib/libc/tests/hash and lib/libc/tests/net/getaddrinfo - Remove unnecessary .include <bsd.own.mk>s (some opportunistic cleanup)
Document the proposed changes in share/examples/tests/tests/... via examples so it's clear that ${PACKAGES}FILES is the suggested way forward in terms of replacing FILES. share/mk/bsd.README didn't seem like the appropriate method of communicating that info.
MFC after: never probably X-MFC with: r298107 PR: 209114 Relnotes: yes Tested with: buildworld, installworld, checkworld; buildworld, packageworld Sponsored by: EMC / Isilon Storage Division
|
298107 |
16-Apr-2016 |
gjb |
Merge the projects/release-pkg branch to head.
This allows packaging the base system with pkg(8), including but not limited to providing the ability to provide upstream binary update possibilities for non-tier-1 architectures.
This merge is a requirement of the 11.0-RELEASE, and as such, thank you to everyone that has tested the project branch.
Documentation in build(7) etc. is still somewhat sparse, but updates to those parts will follow.
Sponsored by: The FreeBSD Foundation
|
296587 |
09-Mar-2016 |
bdrewery |
DIRDEPS_BUILD: Connect MK_TESTS.
Sponsored by: EMC / Isilon Storage Division
|
295435 |
09-Feb-2016 |
kib |
Rename P_KTHREAD struct proc p_flag to P_KPROC.
I left as is an apparent bug in ntoskrnl_var.h:AT_PASSIVE_LEVEL() definition.
Suggested by: jhb Sponsored by: The FreeBSD Foundation
|
291558 |
01-Dec-2015 |
bdrewery |
Update dependencies after r291406 added libelf to libkvm.
Unfortunately filemon/meta mode tracks all indirect dependencies here since ld(1) is reading libelf when linking in libkvm. Churn would be reduced if this was able to be limited to direct dependencies.
Sponsored by: EMC / Isilon Storage Division
|
289172 |
12-Oct-2015 |
ngie |
Refactor the test/ Makefiles after recent changes to bsd.test.mk (r289158) and netbsd-tests.test.mk (r289151)
- Eliminate explicit OBJTOP/SRCTOP setting - Convert all ad hoc NetBSD test integration over to netbsd-tests.test.mk - Remove unnecessary TESTSDIR setting - Use SRCTOP where possible for clarity
MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Divison
|
287012 |
22-Aug-2015 |
jamie |
Make pkill/pgrep -j ARG take jname, not just jid.
PR: 201588 Submitted by: Daniel Shahaf <danielsh at apache.org> MFC after: 3 days
|
284345 |
13-Jun-2015 |
sjg |
Add META_MODE support.
Off by default, build behaves normally. WITH_META_MODE we get auto objdir creation, the ability to start build from anywhere in the tree.
Still need to add real targets under targets/ to build packages.
Differential Revision: D2796 Reviewed by: brooks imp
|
279121 |
21-Feb-2015 |
ngie |
Disguising stderr from jls generally considered harmful
Undisguising it dumps out the following logspew:
jls: unknown parameter: allow
PR: 191019
|
278776 |
14-Feb-2015 |
ngie |
Refactor pkill-j_test to reflect the relevant changes done to pgrep-j_test
r278742:
Simplify jail_name_to_jid and try to be more fault tolerant when scanning for the jail ID (poll up to 10 times for the jail IDs to become available)
If the scan fails, the code will fall through and fail as it does with Jenkins today
r278636:
Parameterize out the amount of sleep done in each test
Set the value in each test to a different amount to avoid potential side-effects with other instances of the test (or lingering processes) still being present on the system
r278633:
Refactor the tests
1. `id -u` -> 0 is now only checked once; the entire test script is now skipped if this assertion is violated 2. De-dent whitespace, based on 1. 3. Only setup the symlink for $sleep once at the top of the script, and tear it down once at the bottom of the script
|
278742 |
14-Feb-2015 |
ngie |
Simplify jail_name_to_jid and try to be more fault tolerant when scanning for the jail ID (poll up to 10 times for the jail IDs to become available)
If the scan fails, the code will fall through and fail as it does with Jenkins today
|
278653 |
13-Feb-2015 |
ngie |
Call wait to ensure that background processes have died
This is being done to establish parity with pgrep-j_test
|
278636 |
12-Feb-2015 |
ngie |
Parameterize out the amount of sleep done in each test
Set the value in each test to a different amount to avoid potential side-effects with other instances of the test (or lingering processes) still being present on the system
|
278633 |
12-Feb-2015 |
ngie |
Refactor the tests
1. `id -u` -> 0 is now only checked once; the entire test script is now skipped if this assertion is violated 2. De-dent whitespace, based on 1. 3. Only setup the symlink for $sleep once at the top of the script, and tear it down once at the bottom of the script
|
278618 |
12-Feb-2015 |
ngie |
Add debugging output to help track down the recent Jenkins failures
|
275028 |
25-Nov-2014 |
bapt |
Convert bin/ to LIBADD, reduce overlinking allow to build all components as static
|
272305 |
30-Sep-2014 |
rodrigc |
Fix pkill unit tests.
- use daemon(8) to write out a pid file for processes, and check for for the existence of that file after killing processes - use explict named parameters to jail(8)
|
269977 |
14-Aug-2014 |
asomers |
Skip pgrep-j and pkill-j if jail or jls is not installed.
Even though jail is part of the base system, it can be disabled by src.conf settings. Therefore, it should be listed as a required program for tests that use it.
CR: D603 MFC after: 3 days Sponsored by: Spectra Logic
|
267667 |
20-Jun-2014 |
bapt |
use .Mt to mark up email addresses consistently (part1)
PR: 191174 Submitted by: Franco Fichtner <franco@lastsummer.de>
|
265420 |
06-May-2014 |
imp |
Use src.opts.mk in preference to bsd.own.mk except where we need stuff from the latter.
|
263351 |
19-Mar-2014 |
jmmv |
Migrate tools/regression/usr.bin/pkill to the new tests layout.
Interestingly, the pkill tool lives in bin, not usr.bin. Haven't bothered to check if this is because the tool moved or because the tests were originally added in the wrong place.
|
257911 |
10-Nov-2013 |
eadler |
pkill - Optimize pgrep -F
Ask for a specific process instead of pulling down all processes when -F <pidfile> is specified. This is much much faster.
Obtained from: DragonflyBSD
|
256050 |
04-Oct-2013 |
trasz |
Remove useless check - ki_loginclass is an array; can't be NULL.
CID: 1006559 Approved by: re (kib) MFC after: 2 weeks Sponsored by: FreeBSD Foundation
|
254134 |
09-Aug-2013 |
trasz |
Add -c flag to pgrep(1) and pkill(1), to match login classes.
MFC after: 1 month
|
218285 |
04-Feb-2011 |
jilles |
Make sys_signame upper case.
This matches the constants from <signal.h> with 'SIG' removed, which POSIX requires kill and trap to accept and 'kill -l' to write.
'kill -l', 'trap', 'trap -l' output is now upper case.
In Turkish locales, signal names with an upper case 'I' are now accepted, while signal names with a lower case 'i' are no longer accepted, and the output of 'killall -l' now contains proper capital 'I' without dot instead of a dotted capital 'I'.
|
209924 |
12-Jul-2010 |
brian |
Add -l to the synopsis
Submitted by: jhell at dataix dot net MFC after: 3 days
|
209363 |
20-Jun-2010 |
brian |
Recognise the -l switch with pkill - list kill command(s) used.
PR: 143558 Submitted by: eitanadlerlist at gmail dot com MFC after: 3 weeks
|
204553 |
02-Mar-2010 |
joel |
The NetBSD Foundation has granted permission to remove clause 3 and 4 from their software.
Approved by: pjd Obtained from: NetBSD
|
203802 |
12-Feb-2010 |
pjd |
- Implement -q option for pgrep(1). - Add regression test to test -q option.
|
203688 |
08-Feb-2010 |
brucec |
Initialize the execfile argument to NULL instead of _PATH_DEVNULL. This allows the -M option to be used without specifying -N.
PR: bin/138146 Approved by: rrs (mentor) MFC after: 3 days
|
202532 |
17-Jan-2010 |
ed |
Raise WARNS for various tools where possible.
Submitted by: Marius NĂ¼nnerich <marius@nuenneri.ch>
|
201487 |
04-Jan-2010 |
obrien |
Committed the wrong version in r201484. This time really fix the "-t" functionality. Per the regression tests (pgrep-t.t & pkill-t.t), "-t" should accept "v1", which means a plain number should be accepted for UNIX98-style PTY's.
|
201484 |
04-Jan-2010 |
obrien |
Fix the "-t" functionality. Per the regression tests (pgrep-t.t & pkill-t.t), "-t" should accept "v1", which means a plain number should be accepted for UNIX98-style PTY's.
|
201145 |
28-Dec-2009 |
antoine |
(S)LIST_HEAD_INITIALIZER takes a (S)LIST_HEAD as an argument. Fix some wrong usages. Note: this does not affect generated binaries as this argument is not used.
PR: 137213 Submitted by: Eygene Ryabinkin (initial version) MFC after: 1 month
|
192242 |
17-May-2009 |
brian |
When finding processes, ignore ourself and our ancestors. It is almost always surprising when you kill a 'sh -c ...' ancestor or when you kill yourself when using -f.
Add a -a switch for backwards compatibility.
MFC after: 3 weeks
|
183502 |
30-Sep-2008 |
ed |
Improve the `pkill -t' handling, which I changed in my previous commit.
In my previous commit I disabled pkill(1)'s automatic prepending of the "tty" string when `pkill -t' was being used. Re-enable it and stat() both possible device names when called.
Requested by: jhb, rwatson (MFC) MFC after: 1 month
|
183438 |
28-Sep-2008 |
ed |
Don't automatically prepend the "tty" prefix to `pkill -t' arguments.
Because we now enforce UNIX98-style PTY's, we now use a lot of TTY's that don't have the traditional /dev/ttyXX naming scheme. pkill(1)'s -t flag automatically prepended the word "tty" to each TTY that was passed on the command line. This meant that `pkill -t pts/0' was actually converted to /dev/ttypts/0. Disable this broken behaviour for now.
Reported by: erwin
|
182543 |
31-Aug-2008 |
yar |
pkill(1) first appeared in /usr/bin, but later it was moved to /bin for the convenience of rc.d. Now it has happily lived there for quite a while. So move the pkill(1) source files from usr.bin to bin, too.
Approved by: gad
|
165382 |
20-Dec-2006 |
ru |
Be more accurate in the description of the -I option: signaling to a process doesn't necessarily kill it.
|
164558 |
23-Nov-2006 |
yar |
Fix and extend the -j option to pkill/pgrep WRT the jail wildcard specifications. Earlier the only wildcard syntax was "-j 0" for "any jail". There were at least two shortcomings in it: First, jail ID 0 was abused; it meant "no jail" in other utils, e.g., ps(1). Second, it was impossible to match processed not in jail, which could be useful to rc.d developers. Therefore a new syntax is introduced: "-j any" means any jail while "-j none" means out of jail. The old syntax is preserved for compatibility, but now it's deprecated because it's limited and confusing.
Update the respective regression tests. While I'm here, make the tests more complex but sensitive: Start several processes, some in jail and some out of jail, so we can detect that only the right processes are killed by pkill or matched by pgrep.
Reviewed by: gad, pjd MFC after: 1 week
|
161463 |
20-Aug-2006 |
yar |
Tell in a comment that the symlinks from /usr/bin are for compatibility with other OS types, too.
Pointed out by: gad
|
161458 |
19-Aug-2006 |
yar |
Install pkill(1), aka pgrep(1), to /bin so that rc scripts can use this small and nifty utility. Create compatibility symlinks from /usr/bin for the time being to avoid breaking custom scripts relying on the hardcoded path to the utility.
If pkill(1) takes root, its source should be repocopied some day to src/bin.
Idea by: des Discussed with: brooks (in cvs-src and cvs-all)
|
152568 |
18-Nov-2005 |
ru |
-mdoc sweep.
|
152521 |
16-Nov-2005 |
pjd |
Sync as close as possible with NetBSD. This includes fixes and cleanups listed below:
- If a process dissappears while we are signalling it, don't count it as a match/error. - Better handling of errors and messages. - Downgrade failure to kill(2) (other than ESRCH) from fatal error to a warning; otherwise processing aborts and possibly matching killees would remain unsignalled. This makes pkill match the Solaris behavior. - Exit with 2 on usage errors as documented.
Obtained from: NetBSD Glanced at by: maintainer (gad) [a bit different version of this patch]
|
152518 |
16-Nov-2005 |
pjd |
I often find myself doing:
% pgrep <something> [to verify which processes match] % pkill <something>
To speed such operation up, add -I option which works like rm(1)'s -i option (unfortunately -i is already used in pkill(1)), ie. pkill will ask for confirmation before killing each matching process.
After adding -j, -F, -i, -S, -o and -L options and other improvements, I think I can add myself to the copyright header.
Glanced at by: maintainer (gad)
|
149471 |
25-Aug-2005 |
pjd |
Revert previous behaviour of '-F' option and add '-L' option, which will tell pkill(1)/pgrep(1) to try to flock(2) pidfile before reading PID from there.
Discussed with: jhb, gad
|
149435 |
24-Aug-2005 |
pjd |
Modify '-F' option to work nicely with pidfile(3) - a pidfile given as an argument has to be locked.
|
147370 |
14-Jun-2005 |
ru |
Markup and wording fixes.
Approved by: re (blanket)
|
143879 |
20-Mar-2005 |
pjd |
Whitespace fixes.
|
143878 |
20-Mar-2005 |
pjd |
- Introduce an '-o' option which allows to match oldest of the matching processes. This option can be also found in Solaris and Linux. - Use timercmp(9) macro for timeval comparsion. - Include time.h directly, don't depend on stat.h doing it for us.
Reviewed by: gad (first point) MFC after: 3 days
|
143877 |
20-Mar-2005 |
pjd |
- Introduce '-S' option which allows to match system processes (pgrep only). - Rename IS_KERNPROC() macro to PSKIP() and extend its functionality. Now it'll skip calling process and system processes when -S is not given. As a side effect it fixes '-n' option. Before it was always matching calling process (because of missing 'if (kp->ki_pid == mypid)' check) and after that, calling process was ignored. - When '-l' option is given and there are no arguments, use p_comm as an arguments list (this is helpful for kernel threads matching).
Reviewed by: gad MFC after: 3 days
|
143876 |
20-Mar-2005 |
pjd |
Sort options properly.
Reviewed by: gad MFC after: 3 days
|
143875 |
20-Mar-2005 |
pjd |
Add a -i option to ignore case in the process match.
Obtained from: NetBSD Reviewed by: gad MFC after: 3 days
|
143874 |
20-Mar-2005 |
pjd |
Add and document '-F' option which allows to use file where PID is stored for matching.
Reviewed by: gad MFC after: 3 days
|
143873 |
20-Mar-2005 |
pjd |
Add and document '-j' option which allows to match processes based on its jail ID.
Reviewed by: gad MFC after: 3 days
|
143079 |
03-Mar-2005 |
delphij |
If a user or group is not known, report the problem user/group, rather than the first user/group. Caused huge fun in error messages from large script. Old: pgrep -u root,NoSuchUser,daemon -> pgrep: unknown user `root' Now: pgrep -u root,NoSuchUser,daemon -> pgrep: unknown user `NoSuchUser'
Obtained from: NetBSD (rev. 1.8) MFC After: 1 week (if re@ would have approved this)
|
137670 |
13-Nov-2004 |
ru |
Removed bitrot.
|
133804 |
16-Aug-2004 |
gad |
Document the fact that matching against a process command-name will only work on the first MAXCOMLEN (19) characters of that name.
Noticed by: Peter Holm
|
132370 |
18-Jul-2004 |
stefanf |
Don't forget the arguments for -M and -N in the DESCRIPTION section.
|
132198 |
15-Jul-2004 |
tjr |
Respect locale settings from the environment.
|
130640 |
17-Jun-2004 |
phk |
Second half of the dev_t cleanup.
The big lines are: NODEV -> NULL NOUDEV -> NODEV udev_t -> dev_t udev2dev() -> findcdev()
Various minor adjustments including handling of userland access to kernel space struct cdev etc.
|
129438 |
19-May-2004 |
ru |
Added pgrep to the SYNOPSIS. Fixed SYNOPSIS. Fixed markup nits.
|
127622 |
30-Mar-2004 |
gad |
Use KERN_PROC_PROC instead of KERN_PROC_ALL on the call to kvm_getprocs(), so we get one line per process instead of one for each kernel-thread.
Noticed by: ache & tjr
|
127472 |
27-Mar-2004 |
gad |
bde also tells me that he is confident that P_SYSTEM will not work any better on 4.x than it does on 5.2. If that's true then there is no point to the __FreeBSD_version check that I had added.
|
127470 |
27-Mar-2004 |
gad |
Some style(9)-ish improvements, courtesy of bde.
Noticed by: bde
|
127462 |
26-Mar-2004 |
gad |
Remove the _PATH_DEVNULL setting for "swapf". From the kvm_open(3) man page: The swapfile argument is currently unused.
Noticed by: ru
|
127457 |
26-Mar-2004 |
gad |
Remove the NEED_KMEM support meant for FreeBSD 3.x. This base-system version isn't going to be committed to that branch...
Noticed by: des
|
127456 |
26-Mar-2004 |
gad |
Switch to checking P_KTHREAD instead of P_SYSTEM when deciding what "system processes" to always ignore. Based on my testing with `-D', I am pretty sure this is what we want for 5.x-current. If my thinking is wrong, this also makes it easier to switch to a different check.
|
127445 |
26-Mar-2004 |
ru |
Avoid the manpage layering violation and low-level implementation details of libkvm, and just tell what the getbootfile(3) function will return, by using the text from netstat(1) and dmesg(8).
|
127444 |
26-Mar-2004 |
ru |
Correct the description of options -N and -M to match reality.
|
127437 |
26-Mar-2004 |
ru |
Apply style.Makefile(5).
|
127434 |
26-Mar-2004 |
gad |
Send those -Debug messages to stderr, not stdout...
|
127433 |
26-Mar-2004 |
gad |
Add a debugging option, as I don't understand something that I'm seeing. (this is a probably temporary option, and is not to be documented)
|
127432 |
26-Mar-2004 |
gad |
Remove a redundant check against mypid (the check is done later, in the "Take the appropriate action" section).
Obtained from: the sysutils/pkill port
|
127431 |
26-Mar-2004 |
gad |
Add a cast to get this to compile with WARNS=5 on sparc64. This is needed because off_t == __int64_t, while size_t == __uint64_t. This also compiles with WARNS=5 on amd64, but I haven't tested the other platforms yet.
|
127430 |
26-Mar-2004 |
gad |
Fixes so this will compile with WARNS=5 on i386.
|
127429 |
25-Mar-2004 |
gad |
Fix two cosmetic style(9) issues.
|
127428 |
25-Mar-2004 |
gad |
Add a comment for when these utilities were added to FreeBSD, and add a cross-reference to killall(1).
|
127427 |
25-Mar-2004 |
gad |
Add `-M' and `-N' options to `pkill' and `pgrep', similar to what are supported in `ps':
-M Extract values associated with the name list from the specified core instead of the default /dev/kmem. -N Extract the name list from the specified system instead of the default /kernel.
Written by: Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org> Obtained from: the sysutils/pkill port
|
127426 |
25-Mar-2004 |
gad |
Use the correct type for some casts, thus avoiding a few warning messages when compiling with WARNS=3
Written by: Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org> Obtained from: the sysutils/pkill port
|
127425 |
25-Mar-2004 |
gad |
Change some routine and variable names to match the FreeBSD system.
Written by: Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org> Obtained from: the sysutils/pkill port
|
127412 |
25-Mar-2004 |
gad |
Add the `pkill' and `pgrep' commands from NetBSD. This is the source straight from NetBSD (except to add the RCS-ID lines for FreeBSD). These will probably require a few updates before they are added to the FreeBSD buildworld. I might MFC these to 4.x-stable after 4.10.
Discussed on: freebsd-arch Obtained from: NetBSD (and OpenBSD also has these)
|