Adding new volumes to Ubuntu 20.04

24 views
Skip to first unread message

Ken Harford

unread,
Apr 4, 2022, 3:54:15 PMApr 4
to Packer
Hi Packer people,

I am having a terrible time trying to create new volumes for /tmp /var /home via packer.

I am using /dev/nvme1n* for my volumes having permission issues when trying to write to new volumes.

I am able to make mkfs on the volumes and mount them.

==> amazon-ebs.example: Provisioning with shell script: /tmp/packer-shell3185452200
==> amazon-ebs.example: mke2fs 1.45.5 (07-Jan-2020)
    amazon-ebs.example: Creating filesystem with 5242880 4k blocks and 1310720 inodes
    amazon-ebs.example: Filesystem UUID: 850a46bc-82e4-4f46-a203-fce34dc66ba3
    amazon-ebs.example: Superblock backups stored on blocks:
    amazon-ebs.example:     32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
    amazon-ebs.example:     4096000
    amazon-ebs.example:
    amazon-ebs.example: Allocating group tables: done
    amazon-ebs.example: Writing inode tables: done
    amazon-ebs.example: Creating journal (32768 blocks): done
    amazon-ebs.example: Writing superblocks and filesystem accounting information: done
    amazon-ebs.example:
    amazon-ebs.example: /dev/nvme1n1 /tmp ext4 defaults 1 2
==> amazon-ebs.example: Uploading ./defaults.cfg => /tmp/defaults.cfg
==> amazon-ebs.example: Upload failed: scp: /tmp/defaults.cfg: Permission denied

Any help or suggestions would be greatly appreciated?

Thanks
Ken

Alvaro Miranda Aguilera

unread,
Apr 5, 2022, 5:26:15 PMApr 5
to packe...@googlegroups.com
Can you share a Zip file with packer template and scripts?

File provisioning will happen with the user you defined for connection

/tmp and /var/tmp require special permissions
I think 1777

As the system is already running, if you still have issues after setting permissions, you could mount those devices in auxiliary path, or update /etc/fstab and try reboot


Alvaro




--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/hashicorp/packer/issues
IRC: #packer-tool on Freenode
---
You received this message because you are subscribed to the Google Groups "Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/packer-tool/6159a748-c8e4-455c-912f-aec366948645n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages