strange permissions problem on startup

From: Jon Piesing <[email protected]>
Date: Fri, 29 Nov 1996 16:52:35 +0000

I have a rather strange permissions problem with squid (1.0.20) on
a Sun Ultra 170E (Solaris 2.5).

I'm trying to start it from /etc/rc3.d with a little shell script
like this :-

#!/bin/sh
#(@)/etc/rc3.d/S99http.cache
# startup script for squid HTTP cache server

SQUIDHOME="/etc/squid" ; export SQUIDHOME

killproc ()
{ pid=`/bin/ps -e | grep $1 | awk '{ print $1 }'`
        [ "pid" != "" ] && kill $pid
}

case "$1" in
'start')
        echo "Starting Squid ... "

        ${SQUIDHOME}/bin/squid >/tmp/squid.out 2>&1 &
        ;;
'stop')
        killproc squid
        ;;
esac

The instance of squid started by this script fails and puts the
following messages in cache.log :-

[28/Nov/1996:19:12:55 +0000] main.c:418: Starting Squid Cache
version 1.0.20 for sparc-sun-solaris2.5...
[28/Nov/1996:19:12:55 +0000] main.c:421: With 1024 file
descriptors available
[28/Nov/1996:19:12:55 +0000] ipcache.c:216: Performing DNS Tests...
[28/Nov/1996:19:12:55 +0000] ipcache.c:1129: Successful DNS name
lookup tests...
[28/Nov/1996:19:12:55 +0000] ipcache.c:1070: ipcacheOpenServers:
Starting 5 'dns_server' processes
[28/Nov/1996:19:12:56 +0000] neighbors.c:888: neighbors_init:
Initializing Neighbors...
[28/Nov/1996:19:12:56 +0000] neighbors.c:903: Adding a parent:
fw1.prl.research.philips.com/80/7
[28/Nov/1996:19:12:56 +0000] filemap.c:137: file_map_create:
creating space for 2097152 files
[28/Nov/1996:19:12:56 +0000] store.c:1568: Rebuilding storage from
disk image in /export/home/squid/cache
[28/Nov/1996:19:13:00 +0000] disk.c:203: file_open: error
opening file /export/home/squid/cache/log.new: (13) Permission denied
[28/Nov/1996:19:13:00 +0000] store.c:1592:
storeStartRebuildFromDisk: /export/home/squid/cache/log.new: (13)
Permission denied
FATAL: storeStartRebuildFromDisk: Can't open tmp swaplog
Squid Cache (Version 1.0.20): Terminated abnormally.
CPU Usage: user 0 sys 0
Memory Usage: rss 0 KB
Page faults with physical i/o: 0

I'm not at all clear why this is happening since I can start squid using
this same
script by hand later and there are no problems.

The directory containing the cache and log directories is owned by root
but it's the same
as my test machine which works.

prsun11b{jon}58: ls -l /export/home/squid/
total 12
drwxrwxr-x 102 root other 1536 Nov 28 23:55 cache
drwxrwxr-x 2 root other 512 Nov 28 23:55 logs
drwxrwxr-x 3 root other 1536 Nov 28 23:55 stats
drwxrwxr-x 3 root other 512 Oct 30 10:43 support

Can anybody suggest what is happening and how to fix it. I guess that if
I make the
logs directory world write-able then that will fix it but I don't really
want to do that.

Thanks

Jon
Received on Fri Nov 29 1996 - 09:23:50 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:33:41 MST