Temporary resource disk mounted as /mnt and no swap on rhel8 sku 8-lvm-gen2 latest
See original GitHub issueAfter installing the latest 8-lvm-gen2 RHEL8 on a B4ms I noticed that the /mnt/resource partition is not being mounted and that there is no swap being created. Instead it seems cloud-init has provisioned the disk like this:
# cat /etc/fstab |grep cloud
/dev/disk/cloud/azure_resource-part1 /mnt auto defaults,nofail,x-systemd.requires=cloud-init.service,comment=cloudconfig 0 2
Please advise if this behavior is wanted and recommended or if waagent should handle the resource disk and swap. Currently it seems this is explicitly set via waagent.conf in that image. RHEL 8.1 had different defaults.
Distro and WALinuxAgent details (please complete the following information):
- RHEL 8.2 WALinuxAgent-2.2.46-1.el8.5.noarch
- WALinuxAgent version
# waagent --version
WALinuxAgent-2.2.46 running on redhat 8.2
Python: 3.6.8
Goal state agent: 2.2.49.2
the image is with WALinuxAgent-2.2.38-1.el8, I did run yum update afterwards.
Issue Analytics
- State:
- Created 3 years ago
- Comments:22 (4 by maintainers)
Top Results From Across the Web
Swap file is not re-created after a Linux VM restarts
Describes how to resolve the problem that prevents a swap file from being ... EnableSwap=n #Mount point for the resource disk ResourceDisk.
Read more >Chapter 14. Getting started with swap - Red Hat Customer Portal
Swap space in Linux is used when the amount of physical memory (RAM) is full. If the system needs more memory resources and...
Read more >Mount point changes and Non-standard SWAP disk creation ...
When you try to modify the SWAP disk or work with the temporary disk and want to change the mount point and related...
Read more >Is it safe to store a swap-file on the Temporary Disk on Azure?
On Windows virtual machines, this is done by default. On Linux VMs this should be safe too, unless the system expects the swap...
Read more >azure - Swapfile is not created after reboot using cloud-init
We change the mount point of the Azure temporary disk (ephemeral0) to /mnt/resource . In addition I create a swapfile on the temporary...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
What was the motivation and/or standard for mounting the resource/temporary/ephemeral disk directly to
/mnt
? Per my understanding of the Linux Filesystem Hierarchy Standard (FHS),/mnt
is to be a location for temporarily-mounted filesystems, not a temporary file system itself. This wrecks havoc with other standards and systems that depend on having existing mount point available under/mnt
- which isn’t possible when the entire disk may be re-created on a whim.@saimsh-msft thanks for clarifying the suggested best practice.
This didn’t used to be the default. I think one reason this issue exists is that in my ~20 years of Linux administration it has been “not recommended” to clobber the entire /mnt directory with a single filesystem.
Going forward on the next build, would your team consider following established practices and mount the ephemeral disk at /mnt/resource like it used to be?