Thank you for visiting the Rackspace Community
The Community is currently in read-only mode. All content is available, but the ability to post new content or topics is not available at this time.

Please contact your support team if you have a question or need assistance for any Rackspace products, services, or articles.

How to install all-in-one(klio) when i am out of the internet? Help!

This question is not answered.

Hi,

since i am out of the internet, i download the install packages (openstack-ansible-master), and put it in the directory(/opt),

cd /opt/openstack-ansible
scripts/bootstrap-aio.sh ---it comes out that "scripts/bootstrap-aio.sh: line 28: ansible-playbook: command not found"
scripts/bootstrap-ansible.sh ---it seems that it cannot connect the internet, and failure
scripts/run-playbooks.sh ---it also needs to touch the internet, and "openstack-ansible: command not found"

As i am a new learner for openstack, any information is appreciated.
All Replies
  • Hey heyao,


    The error you get trying to run bootstrap-aio.sh is because bootstrap-ansible.sh should be the first script run which will install ansible and ansible-playbook along with other needed files/binaries. Are  you trying to perform this install while not being connected to the internet? If so, unfortunately you will have to download a lot of different things manually. What error(s) are you getting when running the bootstrap-ansible.sh? The errors you provided are both related to bootstrap-ansible.sh not running successfully.


    Kind regards,


    Melvin Hillsman

  • Hey Melvin,

    Thank you for your reply. Yes, can you tell me what things i should download when i am trying to do an offline installation?And here are the information when running the bootstrap-ansible.sh. Should i do some change to the bootstrap-ansible.sh when i am doing an offline installation?

    ……
    + apt-get update
    Err http://us.archive.ubuntu.com trusty InRelease
     
    Err http://us.archive.ubuntu.com trusty-updates InRelease
     
    Err http://us.archive.ubuntu.com trusty-backports InRelease
     
    Err http://security.ubuntu.com trusty-security InRelease
     
    Ign file: trusty InRelease
    Err http://us.archive.ubuntu.com trusty Release.gpg
      Could not resolve 'us.archive.ubuntu.com'
    Ign file: trusty Release.gpg
    Err http://us.archive.ubuntu.com trusty-updates Release.gpg
      Could not resolve 'us.archive.ubuntu.com'
    Err http://security.ubuntu.com trusty-security Release.gpg
      Could not resolve 'security.ubuntu.com'
    Err http://us.archive.ubuntu.com trusty-backports Release.gpg
      Could not resolve 'us.archive.ubuntu.com'
    Ign file: trusty Release
    Err file: trusty/main amd64 Packages
      File not found
    Err file: trusty/restricted amd64 Packages
      File not found
    Err file: trusty/main i386 Packages
      File not found
    Err file: trusty/restricted i386 Packages
      File not found
    Ign file: trusty/main Translation-en_US
    Ign file: trusty/main Translation-en
    Ign file: trusty/restricted Translation-en_US
    Ign file: trusty/restricted Translation-en
    Reading package lists... Done
    W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty/InRelease  

    W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/InRelease  

    W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-backports/InRelease  

    W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/InRelease  

    W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty/Release.gpg  Could not resolve 'us.archive.ubuntu.com'

    W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/Release.gpg  Could not resolve 'us.archive.ubuntu.com'

    W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-backports/Release.gpg  Could not resolve 'us.archive.ubuntu.com'

    W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/Release.gpg  Could not resolve 'security.ubuntu.com'

    W: Some index files failed to download. They have been ignored, or old ones used instead.
    + apt-get -y install git python-all python-dev curl autoconf g++ python2.7-dev
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    Package autoconf is not available, but is referred to by another package.
    This may mean that the package is missing, has been obsoleted, or
    is only available from another source

    Package python-dev is not available, but is referred to by another package.
    This may mean that the package is missing, has been obsoleted, or
    is only available from another source
    However the following packages replace it:
      python

    Package python-all is not available, but is referred to by another package.
    This may mean that the package is missing, has been obsoleted, or
    is only available from another source

    E: Unable to locate package git
    E: Package 'python-all' has no installation candidate
    E: Package 'python-dev' has no installation candidate
    E: Package 'autoconf' has no installation candidate
    E: Unable to locate package python2.7-dev
    E: Couldn't find any package by regex 'python2.7-dev'
    ++ exit_fail 257 0
    ++ set +x
    ++ cat /openstack/log/instance-info/host_info_1457671802.log
    ----------------------------------------------------------------------

    - [ Current User ] ---------------------------------------------------
    ----------------------------------------------------------------------
    root
    ----------------------------------------------------------------------

    - [ Available Memory ] -----------------------------------------------
    ----------------------------------------------------------------------
     
    - [ Available Disk Space ] -------------------------------------------
    ----------------------------------------------------------------------

    - [ Mounted Devices ] ------------------------------------------------
    ----------------------------------------------------------------------
    /dev/mapper/ubuntu--vg-root on / type ext4 (rw,errors=remount-ro)
    proc on /proc type proc (rw,noexec,nosuid,nodev)
    sysfs on /sys type sysfs (rw,noexec,nosuid,nodev)
    none on /sys/fs/cgroup type tmpfs (rw)
    none on /sys/fs/fuse/connections type fusectl (rw)
    none on /sys/kernel/debug type debugfs (rw)
    none on /sys/kernel/security type securityfs (rw)
    udev on /dev type devtmpfs (rw,mode=0755)
    devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
    tmpfs on /run type tmpfs (rw,noexec,nosuid,size=10%,mode=0755)
    none on /run/lock type tmpfs (rw,noexec,nosuid,nodev,size=5242880)
    none on /run/shm type tmpfs (rw,nosuid,nodev)
    none on /run/user type tmpfs (rw,noexec,nosuid,nodev,size=104857600,mode=0755)
    none on /sys/fs/pstore type pstore (rw)
    /dev/sda1 on /boot type ext2 (rw)
    systemd on /sys/fs/cgroup/systemd type cgroup (rw,noexec,nosuid,nodev,none,name=systemd)
    ----------------------------------------------------------------------

    - [ Block Devices ] --------------------------------------------------
    ----------------------------------------------------------------------
    NAME                         MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
    sda                            8:0    0   100G  0 disk
    |-sda1                         8:1    0   243M  0 part /boot
    |-sda2                         8:2    0     1K  0 part
    `-sda5                         8:5    0  99.8G  0 part
      |-ubuntu--vg-root (dm-0)   252:0    0  91.8G  0 lvm  /
      `-ubuntu--vg-swap_1 (dm-1) 252:1    0     8G  0 lvm  [SWAP]
    sdb                            8:16   0    70G  0 disk
    sr0                           11:0    1  1024M  0 rom  
    ----------------------------------------------------------------------

    - [ Block Devices Information ] --------------------------------------
    ----------------------------------------------------------------------
    /dev/sda1: UUID="a13fa5d1-e883-474d-b46c-ff817a4e33d1" TYPE="ext2"
    /dev/sda5: UUID="0esic4-rR1a-UuPZ-UoeH-1bU1-SgsJ-YsFo4z" TYPE="LVM2_member"
    /dev/mapper/ubuntu--vg-root: UUID="cf4d7471-cb91-4c23-97b1-e320f0eb175e" TYPE="ext4"
    /dev/mapper/ubuntu--vg-swap_1: UUID="651d6447-3d1b-41df-974a-8945f0e56b6c" TYPE="swap"
    ----------------------------------------------------------------------

    - [ Block Device Partitions ] ----------------------------------------
    ----------------------------------------------------------------------
    Model: VMware Virtual disk (scsi)
    Disk /dev/sda: 107GB
    Sector size (logical/physical): 512B/512B
    Partition Table: msdos

    Number  Start   End    Size   Type      File system  Flags
     1      1049kB  256MB  255MB  primary   ext2         boot
     2      257MB   107GB  107GB  extended
     5      257MB   107GB  107GB  logical                lvm

    Model: Unknown (unknown)
    Disk /dev/sda1: 255MB
    Sector size (logical/physical): 512B/512B
    Partition Table: loop

    Number  Start  End    Size   File system  Flags
     1      0.00B  255MB  255MB  ext2

    Error: Can't have a partition outside the disk!
    Error: /dev/sda5: unrecognised disk label
    Error: /dev/sdb: unrecognised disk label
    ----------------------------------------------------------------------

    - [ PV Information ] -------------------------------------------------
    ----------------------------------------------------------------------
      PV         VG        Fmt  Attr PSize  PFree
      /dev/sda5  ubuntu-vg lvm2 a--  99.76g 20.00m
    ----------------------------------------------------------------------

    - [ VG Information ] -------------------------------------------------
    ----------------------------------------------------------------------
      VG        #PV #LV #SN Attr   VSize  VFree
      ubuntu-vg   1   2   0 wz--n- 99.76g 20.00m
    ----------------------------------------------------------------------

    - [ LV Information ] -------------------------------------------------
    ----------------------------------------------------------------------
      LV     VG        Attr      LSize  Pool Origin Data%  Move Log Copy%  Convert
      root   ubuntu-vg -wi-ao--- 91.74g                                           
      swap_1 ubuntu-vg -wi-ao---  8.00g                                           
    ----------------------------------------------------------------------

    - [ CPU Information ] ------------------------------------------------
    ----------------------------------------------------------------------

    - [ Container Information ] ------------------------------------------
    ----------------------------------------------------------------------
    ----------------------------------------------------------------------

    - [ Firewall Information ] -------------------------------------------
    ----------------------------------------------------------------------
    Chain INPUT (policy ACCEPT 144K packets, 13M bytes)
     pkts bytes target     prot opt in     out     source               destination         

    Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
     pkts bytes target     prot opt in     out     source               destination         

    Chain OUTPUT (policy ACCEPT 1587 packets, 267K bytes)
     pkts bytes target     prot opt in     out     source               destination         
    Chain PREROUTING (policy ACCEPT 94489 packets, 9359K bytes)
     pkts bytes target     prot opt in     out     source               destination         

    Chain INPUT (policy ACCEPT 17886 packets, 2091K bytes)
     pkts bytes target     prot opt in     out     source               destination         

    Chain OUTPUT (policy ACCEPT 53 packets, 43756 bytes)
     pkts bytes target     prot opt in     out     source               destination         

    Chain POSTROUTING (policy ACCEPT 53 packets, 43756 bytes)
     pkts bytes target     prot opt in     out     source               destination         
    Chain PREROUTING (policy ACCEPT 220K packets, 21M bytes)
     pkts bytes target     prot opt in     out     source               destination         

    Chain INPUT (policy ACCEPT 144K packets, 13M bytes)
     pkts bytes target     prot opt in     out     source               destination         

    Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
     pkts bytes target     prot opt in     out     source               destination         

    Chain OUTPUT (policy ACCEPT 1587 packets, 267K bytes)
     pkts bytes target     prot opt in     out     source               destination         

    Chain POSTROUTING (policy ACCEPT 1587 packets, 267K bytes)
     pkts bytes target     prot opt in     out     source               destination         
    ----------------------------------------------------------------------

    - [ Network Devices ] ------------------------------------------------
    ----------------------------------------------------------------------
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default
        link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
        inet 127.0.0.1/8 scope host lo
           valid_lft forever preferred_lft forever
        inet6 ::1/128 scope host
           valid_lft forever preferred_lft forever
    2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
        link/ether 00:0c:29:14:4b:bb brd ff:ff:ff:ff:ff:ff
        inet 100.115.81.81/16 brd 100.115.255.255 scope global eth0
           valid_lft forever preferred_lft forever
        inet6 fe80::20c:29ff:fe14:4bbb/64 scope link
           valid_lft forever preferred_lft forever
    3: eth1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
        link/ether 00:0c:29:14:4b:a7 brd ff:ff:ff:ff:ff:ff
    ----------------------------------------------------------------------

    - [ Network Routes ] -------------------------------------------------
    ----------------------------------------------------------------------
    default via 100.115.0.1 dev eth0
    100.115.0.0/16 dev eth0  proto kernel  scope link  src 100.115.81.81
    ----------------------------------------------------------------------

    - [ DNS Configuration ] ----------------------------------------------
    ----------------------------------------------------------------------
    # Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
    #     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
    ----------------------------------------------------------------------

    - [ Trace Path from google ] -----------------------------------------
    ----------------------------------------------------------------------
     1?: [LOCALHOST]                                         pmtu 1500
     1:  100.115.0.1                                           2.445ms
     1:  100.115.0.1                                           2.051ms
     2:  no reply
     3:  no reply
     4:  no reply
     5:  no reply
         Too many hops: pmtu 1500
         Resume: pmtu 1500
    ----------------------------------------------------------------------

    - [ XEN Server Information ] -----------------------------------------
    ----------------------------------------------------------------------

    No xenstore Information

    ++ info_block 'Error Info - 257' 0
    ++ echo ----------------------------------------------------------------------
    ----------------------------------------------------------------------
    ++ print_info 'Error Info - 257' 0
    ++ PROC_NAME='- [ Error Info - 257 0 ] -'
    ++ printf '\n%s%s\n' '- [ Error Info - 257 0 ] -' --------------------------------------------

    - [ Error Info - 257 0 ] ---------------------------------------------
    ++ echo ----------------------------------------------------------------------
    ----------------------------------------------------------------------
    ++ exit_state 1
    ++ set +x
    ----------------------------------------------------------------------

    - [ Run Time = 12 seconds || 0 minutes ] -----------------------------
    ----------------------------------------------------------------------
    ----------------------------------------------------------------------

    - [ Status: Failure ] ------------------------------------------------
    ----------------------------------------------------------------------

  • Hello heyao,


    Unfortunately there are far too many things to be downloaded to provide each; I am not aware of them all at this time personally as I have not attempted an offline installation. I can say one this you will want to review is how to setup a local Ubuntu repository based on the error(s) you provided.

    Additionally based on your output, I would suggest making a smaller primary disk and setting your secondary disk to say at least 120G. It appears you are trying to utilize LVM to possibly be able to remove everything easily. It would probably be best to read through the script you are trying to run and pull from it what you will need to download outside of setting up the local repository; this may help with the local repository piece - Setup Local Repository On Ubuntu 14.04/13.10/13.04 Server

    Outside of the Ubuntu packages, there are going to be a number of python packages you will need; again, reading through the script(s) should provide you the information needed for this. However, there are some packages that will depend on others that are not listed so it will more than likely be a tedious process.

    Kind regards,

    Melvin Hillsman

  • Hey Melvin and heyao,

    A few months ago I tried to do an offline OSA install and quickly gave up. As Melvin mentioned, there are just too many calls out to find and intercept them all. What I ended up doing was setting up two VMs in VirtualBox: one with AptCacher-NG installed and another one as a target for an OpenStack all-in-one installation. Then I performed the full installation as documented at http://docs.openstack.org/kilo/install-guide/install/apt/content/ch_preface.html. Once I built the cache VM (this took a few tries, not sure why), I could carry that around with me and perform other OpenStack installations -- this actually worked flawlessly in an air-gapped environment I was working in.

    That was definitely a slightly annoying process, but I put together some Ansible scripts to help. I'll need to check to see if I can open-source those for you.

  • heyao, we can't open-source this code right now, but you have my general approach.

  • Hey Evan,

    Thank you for your help!

    According to your apply, my understanding is that i can install the all-in-one offline with the cache vm, and i can install the cache vm according http://docs.openstack.org/kilo/install-guide/install/apt/content/ch_preface.html. So, my question is that dose the installation of the cache vm need to connect the internet? And how to install the all-in-one offline with the cache vm?

    It's really a hard process, thanks.

  • heyao, let me see if I can make it clear for you:

    1. Set up a cache VM "C" with Apt-Cacher-NG.
    2. Set up a target VM "T" and configure its apt proxy to be C.
    3. With an internet connection on C but not on T, install OpenStack on T. This should create a cache of all the OpenStack packages on C.
    4. Remove the internet connection from C and reset T to a vanilla state (but with the apt proxy configured). Put ACNG in offline mode and try to install OpenStack on T. This should succeed, but if not, you'll need to repeat step 3. We found that it took a few iterations for some reason.
    5. Once you can install OpenStack on T with C offline, you can carry C with you and install OpenStack anywhere offline using C as the apt proxy.

  • Mark my word, Stoner... one day... ONE DAY!