Skip to content

Instantly share code, notes, and snippets.

@timf
timf / hiring.md
Last active August 29, 2015 14:18

Hiring!

The Dell Cloud Manager engineering team is growing.

In this gist, I want to give you an idea of:

  • Who we are looking for
  • What we work on
I asked my email-pal: "UNIX or Windoze?". He replied "UNIX". I said "Ah...me
too!".
I asked my email-pal: "Linux or AIX?". He said "Linux, of course". I said
"Me too".
I asked him: "Emacs or vi". He replied "Emacs". I said "Me too. Small world."
I asked him: "GNU Emacs or XEmacs?", and he said "GNU Emacs". I said "oh, me
too."
@timf
timf / hiring.md
Last active January 18, 2020 22:11
Hiring!

See the more recent gist.

Hiring!

The Dell Cloud Manager engineering team is growing. We're looking for seven new software developers at many different experience levels.

In this gist, I want to give you an idea of:

<
%3C
&lt
&lt;
&LT
&LT;
&#60
&#060
&#0060
&#00060
#!/bin/bash
export MYSQL_PASS=
function mysql_search_schema_usage(){
cat << EOF
usage: $0 <terms> [database]
EOF
}
function mysql_search_schema(){
@timf
timf / tiff-to-png.sh
Created June 20, 2013 01:55
Pass an X.tiff file to this --> X.png
#!/bin/bash
echoerr() { echo "$@" 1>&2; }
if [ "X" == "X$1" ]; then
echoerr "error: requires argument: path to .tiff file"
exit 1
fi
exe=`which sips`
curl http://whatismyip.akamai.com
@timf
timf / gist:4696052
Created February 2, 2013 03:55
Pipe or redirect-output from a sh for loop
(~)$ for x in `seq 5`; do echo $x; done | xargs ls
ls: 1: No such file or directory
ls: 2: No such file or directory
ls: 3: No such file or directory
ls: 4: No such file or directory
ls: 5: No such file or directory
(~)$ for x in `seq 5`; do echo $x; done > tmpfile
(~)$ cat tmpfile
1

Orien is correct, it is the fork() system call triggered by ProcessBuilder or Runtime.exec or other means of the JVM executing an external process (e.g. another JVM running ant, a git command, etc.).

There have been some posts on the Jenkins mailing lists about this: Cannot run program "git" ... error=12, Cannot allocate memory

There is a nice description of the issue on the SCons dev list: fork()+exec() vs posix_spawn()

There is a long standing JVM bug report with solutions: Use posix_spawn, not fork, on S10 to avoid swap exhaustion. But I'm not sure if this actually made it into JDK7 as the comments suggest was the plan.

In summary, on Unix-like systems, when one process (e.g. the JVM) needs to launch another process (e.g. git) a system call is made to