Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S271378AbTHDF1c (ORCPT ); Mon, 4 Aug 2003 01:27:32 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S271379AbTHDF1c (ORCPT ); Mon, 4 Aug 2003 01:27:32 -0400 Received: from [203.53.213.67] ([203.53.213.67]:37903 "EHLO exchange.world.net") by vger.kernel.org with ESMTP id S271378AbTHDF1b (ORCPT ); Mon, 4 Aug 2003 01:27:31 -0400 Message-ID: <6416776FCC55D511BC4E0090274EFEF5080024A9@exchange.world.net> From: Steven Micallef To: "'linux-kernel@vger.kernel.org'" Subject: chroot() breaks syslog() ? Date: Mon, 4 Aug 2003 15:27:27 +1000 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="ISO-8859-1" Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 954 Lines: 33 Hi all, I've stumbled onto what seems to have broken somewhere between 2.4.8 and 2.4.18 (sorry, I've been unable to test it on a later version just yet). Basically, when using chroot(), syslog() calls don't work. The following simple example is broken on 2.4.18: #include #include int main(void) { chroot("/home/steve"); syslog(LOG_ALERT, "TEST"); } An strace reveals the following: connect(3, {sin_family=AF_UNIX, path="/dev/log"}, 16) = -1 ENOENT (No such file or directory) Is this intentional? If so, is there a work-around? I discovered this when debugging 'rwhod', but I imagine there are many more utils that would be affected too. Cheers, Steve Micallef - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/