Re: [Lxc-users] How to start the network services so as to get the IP address using lxc-execute???

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Geordy,

This script gives the IP address of running system, but what I want is to
get the IP address of the containers that are not started using lxc-start,
lxc-start will call /sbin/init to init all the system, but I want to use
lxc-execute that will no init the system.


Hey Greg you said that, it is possible to get the IP address without
starting the containers how can we do this????

And one more question how to start the network services using lxc-execute


Please help me ASAP.


Regards,
Nishant

On Fri, Dec 9, 2011 at 11:03 AM, nishant mungse <nishantmungse@xxxxxxxxx>wrote:

> Hi Geordy,
>
> You said that your script gets the IP from running container, but i dont
> want to use lxc-start I just want the IP address and use lxc-execute to
> start network services.
>
>
> Regards,
> Nishant
>
>
> On Fri, Dec 9, 2011 at 11:00 AM, nishant mungse <nishantmungse@xxxxxxxxx>wrote:
>
>> Hi,
>>
>>
>> Thanks 4 script.
>>
>> Regards,
>> Nishant
>>
>>
>> On Fri, Dec 9, 2011 at 12:18 AM, Geordy Korte <gkorte@xxxxxxxxx> wrote:
>>
>>> Ok, got out of the hellish traffic jam.  Attached the Script I use to
>>> check the IP number of a running machine.
>>>
>>>
>>>
>>>
>>> On Thu, Dec 8, 2011 at 5:48 PM, Geordy Korte <gkorte@xxxxxxxxx> wrote:
>>>
>>>> I have a script that gets the from a running container, if that is what
>>>> you need i post it tommorrow morning. If i forget ST me via the ibm network.
>>>>
>>>> Mvg
>>>>
>>>> Geordy Korte
>>>> (Sent via iphone so shorter then normal)
>>>>
>>>>
>>>> On 8 dec. 2011, at 13:59, nishant mungse <nishantmungse@xxxxxxxxx>
>>>> wrote:
>>>>
>>>>
>>>> Hi Greg,
>>>>
>>>> Thanks 4 reply.
>>>>
>>>> I just want the IP addresses of the containers. And one more thing can
>>>> I get the IP address of containers in sequence for eg. container1 ::
>>>> 198.208.168.1 container 2 :: 198.208.168.2 and like this.
>>>>
>>>> Please help me ASAP.
>>>>
>>>> Regards,
>>>> Nishant
>>>>
>>>> On Thu, Dec 8, 2011 at 5:09 PM, Greg Kurz <gkurz@xxxxxxxxxx> wrote:
>>>>
>>>>> On Thu, 2011-12-08 at 16:03 +0530, nishant mungse wrote:
>>>>> > Hi,
>>>>> >
>>>>> > I want to manually invoke a networking setup to start the network
>>>>> > service to get the IP address of container , But the problem is i
>>>>> > don't want to start the container and want to use lxc-execute.
>>>>> >
>>>>> > When I tried these things happened::
>>>>> >
>>>>> > command :: lxc-execute -n base
>>>>> > -f /home/nishant/ubuntu.conf
>>>>> /var/lib/lxc/base1/rootfs/etc/init.d/networking start
>>>>>
>>>>> Ok... this can't work. lxc-execute is for application containers only:
>>>>> it runs lxc-init instead of standard /sbin/init. The networking script
>>>>> you invoke needs upstart to be already running in the container... You
>>>>> seem to have a system container here, it _MUST_ be started with
>>>>> lxc-start.
>>>>>
>>>>> >
>>>>> > O/P
>>>>> >
>>>>> > Rather than invoking init scripts through /etc/init.d, use the
>>>>> > service(8)
>>>>> > utility, e.g. service networking start
>>>>> >
>>>>> > Since the script you are attempting to invoke has been converted to
>>>>> an
>>>>> > Upstart job, you may also use the start(8) utility, e.g. start
>>>>> > networking
>>>>> > start: Unable to connect to Upstart: Failed to connect to
>>>>> > socket /com/ubuntu/upstart: Connection refused
>>>>> >
>>>>> >
>>>>> > How to start the network services so as to get the IP addresses of
>>>>> > containers?
>>>>> >
>>>>>
>>>>> What's your true need here ? Controlling the containers network
>>>>> services
>>>>> from the host or just knowing the addresses used by the containers ? I
>>>>> guess both are doable in a variety of ways.
>>>>>
>>>>> Cheers.
>>>>>
>>>>> >
>>>>> > Regards,
>>>>> > Nishant
>>>>> >
>>>>> >
>>>>> >
>>>>> >
>>>>> ------------------------------------------------------------------------------
>>>>> > Cloud Services Checklist: Pricing and Packaging Optimization
>>>>> > This white paper is intended to serve as a reference, checklist and
>>>>> point of
>>>>> > discussion for anyone considering optimizing the pricing and
>>>>> packaging model
>>>>> > of a cloud services business. Read Now!
>>>>> > http://www.accelacomm.com/jaw/sfnl/114/51491232/
>>>>> > _______________________________________________ Lxc-users mailing
>>>>> list Lxc-users@xxxxxxxxxxxxxxxxxxxxx
>>>>> https://lists.sourceforge.net/lists/listinfo/lxc-users
>>>>>
>>>>> --
>>>>> Gregory Kurz                                     gkurz@xxxxxxxxxx
>>>>> Software Engineer @ IBM/Meiosys                  http://www.ibm.com
>>>>> Tel +33 (0)534 638 479                           Fax +33 (0)561 400
>>>>> 420
>>>>>
>>>>> "Anarchy is about taking complete responsibility for yourself."
>>>>>        Alan Moore.
>>>>>
>>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Cloud Services Checklist: Pricing and Packaging Optimization
>>>> This white paper is intended to serve as a reference, checklist and
>>>> point of
>>>> discussion for anyone considering optimizing the pricing and packaging
>>>> model
>>>> of a cloud services business. Read Now!
>>>> http://www.accelacomm.com/jaw/sfnl/114/51491232/
>>>>
>>>> _______________________________________________
>>>> Lxc-users mailing list
>>>> Lxc-users@xxxxxxxxxxxxxxxxxxxxx
>>>> https://lists.sourceforge.net/lists/listinfo/lxc-users
>>>>
>>>>
>>>
>>>
>>> --
>>> ==============
>>> Geordy Korte
>>> MSN geordy@xxxxxxxxx
>>>
>>
>>
>
_______________________________________________
Containers mailing list
Containers@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linuxfoundation.org/mailman/listinfo/containers


[Index of Archives]     [Cgroups]     [Netdev]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux