From owner-freebsd-questions@FreeBSD.ORG Wed Feb 20 22:51:44 2013 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3D63BB98 for ; Wed, 20 Feb 2013 22:51:44 +0000 (UTC) (envelope-from bah@bananmonarki.se) Received: from feeder.usenet4all.se (1-1-1-38a.far.sth.bostream.se [82.182.32.53]) by mx1.freebsd.org (Postfix) with ESMTP id 97CADF87 for ; Wed, 20 Feb 2013 22:51:42 +0000 (UTC) Received: from kw.news4all.se (usenet4all.se [82.182.32.53]) by feeder.usenet4all.se (8.13.1/8.13.1) with ESMTP id r1KMpen9097159; Wed, 20 Feb 2013 23:51:41 +0100 (CET) (envelope-from bah@bananmonarki.se) Message-ID: <51255372.8070804@bananmonarki.se> Date: Wed, 20 Feb 2013 23:51:30 +0100 From: Bernt Hansson User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: Jeff Tipton Subject: Re: jail and networking References: <5124F505.4040906@bananmonarki.se> <13CA24D6AB415D428143D44749F57D7201EABA71@ltcfiswmsgmb21> <51250B20.4000308@bananmonarki.se> <512510ED.6080807@mail.com>, <51251496.4050701@bananmonarki.se> <13CA24D6AB415D428143D44749F57D7201EABC1F@ltcfiswmsgmb21> <51251FA5.6030903@mail.com> In-Reply-To: <51251FA5.6030903@mail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Feb 2013 22:51:44 -0000 2013-02-20 20:10, Jeff Tipton skrev: > On 02/20/2013 20:59, Teske, Devin wrote: >> On Wed, 20 Feb 2013, Bernt Hansson wrote: >> >>> On 2013-02-20 19:07, Jeff Tipton wrote: >>>> On 02/20/2013 19:42, Bernt Hansson wrote: >>>>> On 2013-02-20 17:23, Teske, Devin wrote: >>>>>> On Wed, 20 Feb 2013, Bernt Hansson wrote: >>>>>> >>>>>>> Hello list! >>>>>>> >>>>>>> I dont seem to get net working in a test jail. >>>>>>> >>>>>>> These I've tried; >>>>>>> >>>>>>> ftp, fetch, telnet >>>>>>> >>>>>>> They time out. >>>>>>> >>>>>>> Ssh sort of work. >>>>>>> >>>>>>> 32bit# ssh 10.0.0.3 >>>>>>> ssh_askpass: exec(/usr/local/bin/ssh-askpass): No such file or >>>>>>> directory >>>>>>> Host key verification failed. >>>>>>> >>>>>>> jail is 8.3-STABLE i386 GENERIC >>>>>>> >>>>>>> host is FreeBSD 8.3-STABLE amd64 GENERIC >>>>>>> >>>>>>> I'm sure you want more info so just tell me what info. >>>>>> Commonly the problem is that you are "jexec'd" into the jail and I >>>>>> find that tools like ssh, ftp, telnet, etc. don't work when you're in >>>>>> the jail via "jexec" but instead what works way better is if you ssh >>>>>> into the jail (via the jail'd ssh process of course). >>>>>> >>>>>> Does that seem to be the case in your situation? >>>>> If you mean this sshd IsJ 0:00,00 /usr/sbin/sshd >>>>> >>>>> Then no. >>>>> >>>>> %ssh 10.0.0.10 ssh: connect to host 10.0.0.10 port 22: Operation timed >>>>> out >>>>> >>>>> I did have an alias on the host to the jail's ip. >>>>> Tried to restart the jail it went fine, but now I can't jexec in to >>>>> the jail. >>>>> >>>>> testbox# jexec 1 tcsh >>>>> jexec: jail_attach(1): Invalid argument >>>>> >>>>> Sooo... I'm kind of out of ideas. >>>> What does "jls" command say? If you have restarted your jail, it's ID >>>> most likely has changed. >>> The ID did change, didn't know about that, thank you. >>> >>> But still, sshd isn't running in the jail >>> >>> 32bit# ps ax >>> PID TT STAT TIME COMMAND >>> 2385 ?? IsJ 0:00,00 sendmail: Queue runner@00:30:00 for >>> /var/spool/clientmqueue (sendmail) >>> 2391 ?? SsJ 0:00,00 /usr/sbin/cron -s >>> 2464 0 SJ 0:00,01 tcsh >>> 2482 0 R+J 0:00,00 ps ax >>> >>> testbox# ps ax | grep J >>> 2385 ?? IsJ 0:00,00 sendmail: Queue runner@00:30:00 for >>> /var/spool/clientmqueue (sendmail) >>> 2391 ?? SsJ 0:00,00 /usr/sbin/cron -s >>> 2488 0 S+ 0:00,00 grep J >>> >>> testbox is the host. >> A stab in the dark, but... >> >> Did you add sshd_enable="YES" to the jail's rc.conf(5)? > Or, from within the jail, what does > > service sshd status > > say? 32bit# service sshd status sshd is not running.