Issues with waagent.conf and swap
See original GitHub issueI am currently trying to set-up swap on my Ubuntu 16 VM. I am following the standard procedure and have set waagent.conf accordingly:
ResourceDisk.Format=y
ResourceDisk.Filesystem=ext4
ResourceDisk.MountPoint=/mnt/resource
ResourceDisk.EnableSwap=y
ResourceDisk.SwapSizeMB=64000
Just restarting the service does nothing. After rebooting, if I instantly type free -m
I can see the swap. But a moment later it is gone. When I re-check waagent.conf also ResourceDisk.Format
is set to no automatically: ResourceDisk.Format=n
.
On my other vms it works flawlessly. The only difference is, that on this VM I have an encrypted disk, lsblk output:
sdb 8:16 0 678G 0 disk
└─sdb1 8:17 0 678G 0 part
└─xxx 253:1 0 678G 0 crypt /mnt/resource
Any ideas?
Issue Analytics
- State:
- Created 5 years ago
- Comments:9 (5 by maintainers)
Top Results From Across the Web
Swap file is not re-created after a Linux VM restarts
Resolution. To resolve this problem, follow these steps: Disable resource disk formatting and swap configuration within waagent configuration ...
Read more >[WALA][RHEL-7]waagent fails to create swapfile if fstype is ext3
Prepare a RHEL7.3 VM on Azure. Set the following lines in the /etc/waagent.conf: ResourceDisk.Format=y ResourceDisk.Filesystem=ext3 ResourceDisk.EnableSwap=y ...
Read more >Error retrieving swap info from /proc/swaps on RSA ...
Issue. RSA NetWitness host that is deployed in Azure platform shows /var/log/messages ... Update /etc/waagent.conf with below parameters and save it:
Read more >how to fix swap issues in azure vm - nixdrafts
Save the configuration before change as standard practice of servers administrators. #cp –p /etc/waagent.conf /etc/waagent.conf.$date # cat /etc ...
Read more >Mount point changes and Non-standard SWAP disk creation ...
The issue we have seen is that the changes work but only till you restart. ... Step 4 - Edit the /etc/waagent.conf file...
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
@hglkrijger @ejarvi It partly explains what happens, but I am still not sure how to enable swap then.
@psinger let us know if that does not answer your question.