🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.sun
Article #13228

getwd() call problems

#13228
From: Jean-Francois Lamy
Date: Sun, 10 Dec 1989 21:44
18 lines
1436 bytes
teraida!mikel@decwrl.dec.com (Mikel Lechner) writes:
>kae@ihlpm.att.com (Kenneth A Edwards) writes:

>With SunOS4.0 and later releases, Sun introduced a "performance
>improvement" to the "getwd()" library call.  The library function ends up
>"stat()"ing virtually all your mounted filesystems every time your program
>tries to compute its working directory.  This is nearly guaranteed to hang
>up any process makeing a "getwd()" call when a hard-mounted NFS filesystem
>hangs.

Using trace(1) you can easily determine that getwd() will not follow
symbolic links.  So you can avoid this problem by making sure that all NFS
entries in /etc/fstab are actually symbolic links (i.e. mount on  the
symlink -- mount will follow the symlink at mount time and mount on the
directory referenced by the symlink).

Jean-Francois Lamy               lamy@ai.utoronto.ca, uunet!ai.utoronto.ca!lamy
AI Group, Department of Computer Science, University of Toronto, Canada M5S 1A4
Technical Details
Message-ID: <3880@brazos.Rice.edu>
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!rice!sun-spots-request

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!rice!sun-spots-request
From: lamy@ai.utoronto.ca (Jean-Francois Lamy)
Newsgroups: comp.sys.sun
Subject: getwd() call problems
Keywords: Networks
Message-ID: <3880@brazos.Rice.edu>
Date: 10 Dec 89 21:44:52 GMT
Sender: root@rice.edu
Organization: Sun-Spots
Lines: 18
Approved: Sun-Spots@rice.edu
X-Refs:  Original: v8n213
X-Sun-Spots-Digest: Volume 8, Issue 221, message 8 of 10