From owner-freebsd-jail@FreeBSD.ORG Thu Aug 30 10:19:01 2007 Return-Path: Delivered-To: freebsd-jail@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D91C616A41A for ; Thu, 30 Aug 2007 10:19:01 +0000 (UTC) (envelope-from kalnz@kalnz.id.lv) Received: from prime.kalnz.id.lv (prime.kalnz.id.lv [87.226.86.172]) by mx1.freebsd.org (Postfix) with ESMTP id 939B113C48E for ; Thu, 30 Aug 2007 10:19:01 +0000 (UTC) (envelope-from kalnz@kalnz.id.lv) Received: from localhost (unknown [127.0.0.1]) by prime.kalnz.id.lv (Postfix) with ESMTP id 5B8491CEC3; Thu, 30 Aug 2007 13:22:27 +0300 (EEST) X-Virus-Scanned: by amavisd-new at kalnz.id.lv Received: from prime.kalnz.id.lv ([127.0.0.1]) by localhost (prime.kalnz.id.lv [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mFLMXaqAnzVm; Thu, 30 Aug 2007 13:22:23 +0300 (EEST) Received: from [10.40.10.247] (unknown [159.148.19.169]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: kalnz@prime.kalnz.id.lv) by prime.kalnz.id.lv (Postfix) with ESMTP id 7B3051CEC1; Thu, 30 Aug 2007 13:22:23 +0300 (EEST) Message-ID: <46D6989E.6080400@kalnz.id.lv> Date: Thu, 30 Aug 2007 13:14:54 +0300 From: Kalnz User-Agent: Thunderbird 2.0.0.6 (X11/20070824) MIME-Version: 1.0 To: Alexander Leidinger References: <46D29F4B.9070901@kalnz.id.lv> <20070827125450.uqdbto3xiwwk80gg@webmail.leidinger.net> <46D32435.4030707@kalnz.id.lv> <20070829173619.sghqpfenb4swkkk8@webmail.leidinger.net> In-Reply-To: <20070829173619.sghqpfenb4swkkk8@webmail.leidinger.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-jail@freebsd.org Subject: Re: pam _start: system error X-BeenThere: freebsd-jail@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: kalnz@kalnz.id.lv List-Id: "Discussion about FreeBSD jail\(8\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 30 Aug 2007 10:19:01 -0000 Alexander Leidinger wrote: > Quoting Kalnz (from Mon, 27 Aug 2007 22:21:25 +0300): > >> Alexander Leidinger wrote: >>> Quoting Kalnz (from Mon, 27 Aug 2007 12:54:19 >>> +0300): >>> >>>> Hi! >>>> >>>> After installing (in the jail) mysql-server-5.0.45 from ports, >>>> I can`t get up and running my mysql server. >>>> I have to point out that this problem is only inside the jail. >>>> All I have is: >>>> 1) clean mysql-server install >>>> 2) default my.cnf (small systems) >>>> 3) mysql_enable="YES" >>>> >>>> After this server should run, but it didn`t, so I get this: >>>> >>>> # /usr/local/etc/rc.d/mysql-server start >>>> Starting mysql. >>>> su: pam_start: system error >>>> # >>>> >>>> In the logs there is: >>>> su: in openpam_load_module(): no pam_unix.so found >>>> su: pam_start: system error >>>> >>>> In fact pam_unix.so file is present in /usr/lib directory. >>>> I`m sure this is because of jail, but I can`t figure out what could be >>>> the problem. >>> >>> How do you startup the jail, how have you populated the basesystem >>> in the jail initially? What's the size of pam_unix.so, what does >>> "file /usr/lib/pam_unix.so" print? >> I took some info from here when making my first jail : >> http://www.section6.net/wiki/index.php/Creating_a_FreeBSD_Jail >> Anyway I have 2 jails and everything was working fine until now when I >> installed mysql-server and can`t run it inside the jail. > > It's not the installtion instruction as documented by FreeBSD. I use > mysql in an ezjail (ports) created jail. It works without any problems. > >> # file /usr/lib/pam_unix.so output: >> pam_unix.so: symbolic link to `pam_unix.so.3' >> The same output from base system. >> size = 10848 Bytes > > As the size is printed, there's a real file at the end of the link. So > my first idea what the problem is, is busted. ATM I have no further > idea. You would have to "ktrace -i" what the mysql startup is doing > and have a look at the output (man ktrace, man dump). Then you can > maybe check that everything what it tries to touch is there. > > Bye, > Alexander. > At the moment I`ve noticed that mysql do not like 2 files in /etc/pam.d - "su" and "other" which are here by default after freebsd install. In fact in base system mysql works well and /etc/pam.d content is the same. Anyway when I rename or remove these 2 files, mysql starts and run well, it seems there is no problems then. It is clear that it is connected with pam modules. I think I should do some debug when starting mysql as you said to find out where exactly is the problem... -- Edmunds aka Kalnz