Support #10746

Can't upgrade Antman or EdgeLinux

Added by [email protected] over 4 years ago. Updated over 4 years ago.

Status:
Closed
Assignee:
Mario Kaack
% Done:

0%


Description

I posted to the forum (Alias akak01000101) about network weirdness, but
guess it has to be reviewed first. So I thought I would send you an email
since I can't upgrade Antman or EdgeLinux. I haven't physically logged in
since the last upgrade to support (beta) backups (and your engineers logged
in as well.

It all started after patching a Ubuntu LXC antlet. I know it can't be
related, but it may have brought exposed something after that reboot. Once
I patched/reboot the LXC a series of network issues on my Antsle appeared,
but primarily I can't upgrade Antman or EdgeLinux. I reboot and
power-cycled my Antsle in hopes it would possibly start something that was
stopped, and now my Antsle doesn't forward configured websites to Antlets
that are webservers, which was working prior to the reboot. I would
appreciate any help on a direction to look. Other systems use my router as
DNS just fine. All antlets function fine. There have been no router changes
in months.

root@myantsle:~ # ping central.antsle.com
PING central.antsle.com (192.168.1.1) 56(84) bytes of data.

root@myantsle:~ # route
Destination Gateway Genmask Flags Metric Ref Use
Iface
default localhost 0.0.0.0 UG 8 0 0 br0
localhost 0.0.0.0 255.255.255.0 U 0 0 0
virbr1
localhost 0.0.0.0 255.255.255.0 U 0 0 0
virbr2
localhost 0.0.0.0 255.255.0.0 U 0 0 0
docker0
localhost 0.0.0.0 255.255.255.0 U 8 0 0 br0
localhost 0.0.0.0 255.255.255.0 U 0 0 0
virbr0
root@myantsle:~ #

root@myantsle:~ # upgrade-antman
Traceback (most recent call last):
File "", line 1, in
File "/usr/lib64/python2.7/json/init.py", line 291, in load
**kw)
File "/usr/lib64/python2.7/json/init.py", line 339, in loads
return _default_decoder.decode(s)
File "/usr/lib64/python2.7/json/decoder.py", line 364, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib64/python2.7/json/decoder.py", line 382, in raw_decode
raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded
--2019-10-06 09:51:06-- http://central.antsle.com/antman-releases//amanupd-
Resolving central.antsle.com... 192.168.1.1
Connecting to central.antsle.com|192.168.1.1|:80... connected.
HTTP request sent, awaiting response... No data received.
Retrying.

--2019-10-06 09:51:09-- (try: 2)
http://central.antsle.com/antman-releases//amanupd-
Connecting to central.antsle.com|192.168.1.1|:80... connected.
HTTP request sent, awaiting response... No data received.
Retrying.

--2019-10-06 09:51:12-- (try: 3)
http://central.antsle.com/antman-releases//amanupd-
Connecting to central.antsle.com|192.168.1.1|:80... connected.
HTTP request sent, awaiting response... 503 Service Unavailable
2019-10-06 09:51:12 ERROR 503: Service Unavailable.

chmod: cannot access 'amanupd-': No such file or directory
/usr/local/bin/upgrade-antman: line 11: ./amanupd-: No such file or
directory
rm: cannot remove 'amanupd-': No such file or directory
Error while upgrading antman

  • WARNING: antman has already been started

https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=icon
Virus-free.
www.avast.com
https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=link
<#m_-1342014509535291501_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>

History

#1 Updated by Mario Kaack over 4 years ago

Kirk,

I also saw your other message to Daniel.

The following instructions how to reset the edgeLinux OS to version 0.12.1. antlets will remain and the root password will be set to 'antsle'.

**This will remove all docker images and containers.

I found that using 2 USB sticks is the easiest method. The first will be a bootable USB stick, we recommend using SystemRescueCD:
http://www.system-rescue-cd.org/Installing-SystemRescueCd-on-a-USB-stick/
I use a utility called Rufus to create the bootable usb with the sysrescue .iso (https://rufus.akeo.ie)

The second should be at least 32G capacity and formatted with NTFS or exfat file system as one of the uncompressed images is ~16G.

Connect a monitor and keyboard or connect to the terminal via IPMI: https://docs.antsle.com/setup/#4-ipmi

Remove all other USB storage devices.
Boot the antsle from the bootable USB.
Run the command

lsblk

Your bootable USB should be the last device (sdc)
Plug in the 2nd USB and run 'lsblk' again. This USB should now be the last device (sdd). This USB will probably only have 1 partition but may have two. We will need the one using all the storage space (see the 'size' column). I'll use 'sdd1' in the example.

Lets mount the 2nd USB

mkdir /usb2
mount /dev/sdd1 /usb2

Change into the /usb2 directory

cd /usb2

Download the reset script, make it executable, and run the script:

wget https://static-files.antsle.com:8443/edgeLinux/0.12.1/el-reset
chmod +x el-reset
./el-reset

When the script finishes, power off the antsle, remove the USB sticks and reboot.

** The new root password will be 'antsle'.

Login at the prompt and run the command

el-reset-phase2

Let me know how it goes.

#2 Updated by [email protected] over 4 years ago

This all looks really drastic.
Is there ANYTHING I should be backing up?
Will this remove all the nginx settings that forward connections to all my
webservers?
Do i need to backup my Antlets or any data they contain in any way?

-Kirk

On Tue, Oct 15, 2019 at 3:16 PM [email protected] wrote:

Hi there and thank you for contacting Antsle support!

Kirk,

I also saw your other message to Daniel.

The following instructions how to reset the edgeLinux OS to version
0.12.1. antlets will remain and the root password will be set to 'antsle'.

**This will remove all docker images and containers.

I found that using 2 USB sticks is the easiest method. The first will be a
bootable USB stick, we recommend using SystemRescueCD:
http://www.system-rescue-cd.org/Installing-SystemRescueCd-on-a-USB-stick/
I use a utility called Rufus to create the bootable usb with the sysrescue
.iso (https://rufus.akeo.ie)

The second should be at least 32G capacity and formatted with NTFS or
exfat file system as one of the uncompressed images is ~16G.

Connect a monitor and keyboard or connect to the terminal via IPMI:
https://docs.antsle.com/setup/#4-ipmi

Remove all other USB storage devices.
Boot the antsle from the bootable USB.
Run the command

lsblk

Your bootable USB should be the last device (sdc)
Plug in the 2nd USB and run 'lsblk' again. This USB should now be the last
device (sdd). This USB will probably only have 1 partition but may have
two. We will need the one using all the storage space (see the 'size'
column). I'll use 'sdd1' in the example.

Lets mount the 2nd USB

mkdir /usb2
mount /dev/sdd1 /usb2

Change into the /usb2 directory

cd /usb2

Download the reset script, make it executable, and run the script:

wget https://static-files.antsle.com:8443/edgeLinux/0.12.1/el-reset
chmod +x el-reset
./el-reset

When the script finishes, power off the antsle, remove the USB sticks and
reboot.

** The new root password will be 'antsle'.

Login at the prompt and run the command

el-reset-phase2

Let me know how it goes.

https://brainosaur.com/tickets/5202/a8e1159245bf6d376b40fd469b92ba7d

Thank you,

Antsle Customer Support Team

#3 Updated by Mario Kaack over 4 years ago

Kirk,

I was looking at your notes again and am wondering if you upgraded to 0.12.1? You only mention 0.12.0. This may be worth doing first.

upgrade-edgelinux

The reset scripts do backup your nginx virtual hosts files to /root/virtualhosts/. When done you can cp these back to the /etc/nginx/virtualhosts/ directory.

It is always a good idea to backup your data whether nginx .conf files or data in your antlets. I have attached a couple of scripts to export (backup) an existing antlet as a whole to a file and a script to import (restore) the exported file. These are not polished but work fine for a self contained antlet. If the antlet has a vDrive in a different zpool this will not work. It will also loose the snapshots for the antlet.

scp or sftp the scripts to the antsle and make them executable

chmod +x export-antlet
chmod +x import-antlet

export-antlet will create a single backup file. This file is uncompressed so put it in a location with enough space. Do not save to the root home directory, there is only 16G on that partition. Rather save to a zpool or to an external USB.

To export an antlet

./export-antlet ANTLET_NAME DESTINATION_DIRECTORY

Example with antlet named server-1:

export-antlet server-1 /extUSB/backups/

The exported file name will be in the format: antlet_name.date-time.type.ipX.export

server-1.2018-04-17-09-24-37.lxc.ip10.export

You can also scp or sftp the .export file to external storage (another computer) for safe keeping.
You can gzip the file before scp or sftp

gzip server-1.2018-04-17-09-24-37.lxc.ip10.export

and unzip before running the import:

gunzip server-1.2018-04-17-09-24-37.lxc.ip10.export.gz

And import an exported antlet with:

./import-antlet EXPORT_FILE_NAME DESTINATION_ZPOOL ANTLET_NAME

Example:

./import-antlet server-1.2018-04-17-09-24-37.lxc.ip10.export antlets server-1

When importing, be sure to use the same destination zpool and antlet name as the original.
You can run each of these scripts without any options to get the help.

#4 Updated by [email protected] over 4 years ago

HI,

Thanks for all this. It will be a big help. I don't think the upgrade will
help, because most of the issues started before the upgrade and only got
worse after the upgrade.

-kirk

On Wed, Oct 16, 2019 at 10:05 AM [email protected] wrote:

Hi there and thank you for contacting Antsle support!

Kirk,

I was looking at your notes again and am wondering if you upgraded to
0.12.1? You only mention 0.12.0. This may be worth doing first.

upgrade-edgelinux

The reset scripts do backup your nginx virtual hosts files to
/root/virtualhosts/. When done you can cp these back to the
/etc/nginx/virtualhosts/ directory.

It is always a good idea to backup your data whether nginx .conf files or
data in your antlets. I have attached a couple of scripts to export
(backup) an existing antlet as a whole to a file and a script to import
(restore) the exported file. These are not polished but work fine for a
self contained antlet. If the antlet has a vDrive in a different zpool this
will not work. It will also loose the snapshots for the antlet.

scp or sftp the scripts to the antsle and make them executable

chmod +x export-antlet
chmod +x import-antlet

export-antlet will create a single backup file. This file is uncompressed
so put it in a location with enough space. Do not save to the root home
directory, there is only 16G on that partition. Rather save to a zpool or
to an external USB.

To export an antlet

./export-antlet ANTLET_NAME DESTINATION_DIRECTORY

Example with antlet named server-1:

export-antlet server-1 /extUSB/backups/

The exported file name will be in the format:
antlet_name.date-time.type.ipX.export

server-1.2018-04-17-09-24-37.lxc.ip10.export

You can also scp or sftp the .export file to external storage (another
computer) for safe keeping.
You can gzip the file before scp or sftp

gzip server-1.2018-04-17-09-24-37.lxc.ip10.export

and unzip before running the import:

gunzip server-1.2018-04-17-09-24-37.lxc.ip10.export.gz

And import an exported antlet with:

./import-antlet EXPORT_FILE_NAME DESTINATION_ZPOOL ANTLET_NAME

Example:

./import-antlet server-1.2018-04-17-09-24-37.lxc.ip10.export antlets server-1

When importing, be sure to use the same destination zpool and antlet name
as the original.
You can run each of these scripts without any options to get the help.

https://brainosaur.com/tickets/5202/a8e1159245bf6d376b40fd469b92ba7d

Thank you,

Antsle Customer Support Team

#5 Updated by [email protected] over 4 years ago

I try exporting the antlets. The go through the Antsle reset process.
Antman isn't showing any of my backups I've made to the cloud, and it
doesn't let me make any new backups. I just tried to upgrade-edgelinux to
0.12.1 and there was an Error:

** The '/antlets/_edgeLinux-workspace/rootbak' file exists (most likely
from running previous edgeLinux upgrades).*

  • * This file is not deleted automatically as it contains your previous environment backup and should only be deleted if the edgeLinux upgrade completed successfully, you checked your antlets and data are there. We typically recommend to keep last 3 backups but is up to you.*
  • * Please either remove or rename the directory: /antlets/_edgeLinux-workspace/rootbak* Error while upgrading edgeLinux

I just noticed that the

On Wed, Oct 16, 2019 at 10:59 AM kirk waingrow [email protected]
wrote:

HI,

Thanks for all this. It will be a big help. I don't think the upgrade will
help, because most of the issues started before the upgrade and only got
worse after the upgrade.

-kirk

On Wed, Oct 16, 2019 at 10:05 AM [email protected] wrote:

Hi there and thank you for contacting Antsle support!

Kirk,

I was looking at your notes again and am wondering if you upgraded to
0.12.1? You only mention 0.12.0. This may be worth doing first.

upgrade-edgelinux

The reset scripts do backup your nginx virtual hosts files to
/root/virtualhosts/. When done you can cp these back to the
/etc/nginx/virtualhosts/ directory.

It is always a good idea to backup your data whether nginx .conf files or
data in your antlets. I have attached a couple of scripts to export
(backup) an existing antlet as a whole to a file and a script to import
(restore) the exported file. These are not polished but work fine for a
self contained antlet. If the antlet has a vDrive in a different zpool this
will not work. It will also loose the snapshots for the antlet.

scp or sftp the scripts to the antsle and make them executable

chmod +x export-antlet
chmod +x import-antlet

export-antlet will create a single backup file. This file is uncompressed
so put it in a location with enough space. Do not save to the root home
directory, there is only 16G on that partition. Rather save to a zpool or
to an external USB.

To export an antlet

./export-antlet ANTLET_NAME DESTINATION_DIRECTORY

Example with antlet named server-1:

export-antlet server-1 /extUSB/backups/

The exported file name will be in the format:
antlet_name.date-time.type.ipX.export

server-1.2018-04-17-09-24-37.lxc.ip10.export

You can also scp or sftp the .export file to external storage (another
computer) for safe keeping.
You can gzip the file before scp or sftp

gzip server-1.2018-04-17-09-24-37.lxc.ip10.export

and unzip before running the import:

gunzip server-1.2018-04-17-09-24-37.lxc.ip10.export.gz

And import an exported antlet with:

./import-antlet EXPORT_FILE_NAME DESTINATION_ZPOOL ANTLET_NAME

Example:

./import-antlet server-1.2018-04-17-09-24-37.lxc.ip10.export antlets server-1

When importing, be sure to use the same destination zpool and antlet name
as the original.
You can run each of these scripts without any options to get the help.

https://brainosaur.com/tickets/5202/a8e1159245bf6d376b40fd469b92ba7d

Thank you,

Antsle Customer Support Team

Add a comment