opnsense-starterkit
opnsense-starterkit copied to clipboard
AWS import does not work
When exporting the image to aws and importing it it fails with
"StatusMessage": "ClientError: No valid partitions. Not a valid volume."
Tried to use MBR as the layout for the bootloader, but did not help. The image does work in KVM/VBox anyway.
could be related to the partition layout
to import, i tried 2 things
./tools/package_for_cloud.sh
and then uploaded output/cloud/disk.raw
to an S3 then
imported using this as disk.json
[
{
"Description": "First disk",
"Format": "raw",
"UserBucket": {
"S3Bucket": "vmsharekw",
"S3Key": "opnsense/disk.raw"
}
}
Tried the very same with importing the OVF into vbox and exporting as an v2 OVA - same result. Also tried to use the VMDK, same result
Hello,
For me it's works with:
- Make a raw from a VMDK
- Upload to S3 bucket
- Upload a snapshot with aws ec2 import-snapshot --description "OPNSene 18.1.6" --disk-container file://containers.json
- Convert the snapshot to image with Virtualization type to "Hardware-assisted virtualization"
- Deploy an instance
- Run the instance
At this time, Opnsense is load but the default interface is LAN with 192.168.1.1 IP. I have to find a workaround for that...
thats awesome!
AWS authorize only one NIC on the image ... When Opnsense start the default is LAN with autoconfigure 192.168.1.1 IP. There is no console on AWS to modify somethings in the instance. If someone have an idea !
you need to predploy a configuration as I did, where you open the ssh port and activate ssh from the start + have either a default password or a predployed key. check my work for that
It's works ! (manualy at this time, but i will check your automation asap).
Thanks for your help ! On the road again with Opnsense AMI.
@Zophren any news on this?
I haven't tested but this will probably remove the need for predeploying a configuration: https://aws.amazon.com/about-aws/whats-new/2021/03/introducing-ec2-serial-console/
Hello,
For me it's works with:
- Make a raw from a VMDK
- Upload to S3 bucket
- Upload a snapshot with aws ec2 import-snapshot --description "OPNSene 18.1.6" --disk-container file://containers.json
- Convert the snapshot to image with Virtualization type to "Hardware-assisted virtualization"
- Deploy an instance
- Run the instance
At this time, Opnsense is load but the default interface is LAN with 192.168.1.1 IP. I have to find a workaround for that...
i have trying this but, when launching an instance, i got error on "Instance status check"(system status check is passed no error), how to solve this?
ec2 instance status:
{
"InstanceStatuses": [
{
"AvailabilityZone": "ap-southeast-1c",
"InstanceId": "i-xxxxxxxxxxxxxxxa8",
"InstanceState": {
"Code": 16,
"Name": "running"
},
"InstanceStatus": {
"Details": [
{
"ImpairedSince": "2023-08-02T07:19:00+00:00",
"Name": "reachability",
"Status": "failed"
}
],
"Status": "impaired"
},
"SystemStatus": {
"Details": [
{
"Name": "reachability",
"Status": "passed"
}
],
"Status": "ok"
}
}
]
}