Tag Archives: freebsd

Cron can’t start PAM on FreeBSD

I was having these error messages in /var/log/cron: Feb 29 15:52:01 localhost /usr/sbin/cron[96178]: in openpam_load_module(): no pam_nologin.so found Feb 29 15:52:01 localhost /usr/sbin/cron[96178]: (CRON) error (can’t start PAM Searched the net, couldn’t find anything relevant. Eventually, though, figured out to /etc/rc.d/cron restart, and voila! Maybe something went hazy after upgrade.

PHP doesn’t execute scripts

Neither using CLI (with -f or a shebang) nor through Apache. It was just dumping the script to stdout, and that means short PHP tags (<? … ?>) are disabled. Nothing serious, fixed in php.ini. But then it just did nothing. No output, no errors, no warnings. Turned out this particular version of PHP can’t [...]

csh: Cannot open /etc/termcap

Upon logging into my remote server with ssh, I started getting: csh: Cannot open /etc/termcap. csh: using dumb terminal settings. There is no rxvt-unicode entry in /etc/termcap. You should specify one, but if you’re lazy, you can just setenv TERM xterm in your ~/.cshrc. P.S. Nah, this doesn’t help. You have to put that line [...]

A move to Arch Linux

As if there wasn’t enough changes in my life lately, I’ve switched from FreeBSD to Arch Linux. I did this, since a lot of software is first developed on Linuxes, so that gets the bleeding edge. Such as wireless drivers, window managers, etc.. This wasn’t the only reason, though. I like the strict GPL licence [...]

Notes on enlarging my /usr, FreeBSD

First, introduce yourself to man fdisk, bsdlabel, growfs. Quick link: this. Refer for good detailed instructions. —– Those with extensive Windows experience might think of “resizing the FreeBSD partition”, but that’s not how it works in FreeBSD. When you search the net, the first thing you’ll find is people saying you should use growfs to [...]

Stock FTP with chroot (FreeBSD 7.0)

I was having really weird problems trying to set up a user that would be properly chrooted. Here are some traps/pitfalls. 1) The stock ftpd is not native! It’s merged in from NetBSD (I think). If you look for /usr/share/examples/ftpd/ftpd.conf, you won’t find it. 2) Make sure /home can be executed by anyone. I had [...]

MLDonkey can’t compile: Tcl/Tk missing

Installing from packages: ml_togl.c:12:17: error: tcl.h: No such file or directory ml_togl.c:13:16: error: tk.h: No such file or directory This happens because some dependencies aren’t in the requirements list: portinstall tclX tcllib tk The first two will handle the tcl.h dependency. The second will do tk.h. You should probably make sure tk is the same [...]

A PHP script to resize all images in a directory

This is a crude hack to resize images in a directory. The script is invoked as: shrink <new_x> <new_y> <file> <file> <file> … You’ll need PHP with the GD library. That’s php5-gd on FreeBSD. #!/usr/local/bin/php # The output is JPEG, quality 88. <?php // Fuction to resize images, originally by D. Weimer. // Code reformatting [...]

Octave – open-source alternative to MatLAB

There are some links on osalt.com, and Octave even boasts language compatibility. Will try it out and see how it works. I wonder most whether it has something like MatLAB’s toolboxes. EDIT: Ah, yes, there are: …the toolboxes that exist are donated by those interested in them… (From the FAQ.)

Simple SSH account blocking, FreeBSD

Read the man page! There you’ll find that it’s performed in /etc/ssh/sshd_config by a troup of four directives: DenyUsers AllowUsers DenyGroups AllowGroups In that order. Say you’ve got group users with users jack, off, and jill, and group assholes with jack and jill. If you want only jill to be able to login, you could [...]

Follow

Get every new post delivered to your Inbox.