Is this what you are suggesting to put in Edit Startup Lua ?
[code]local file = io.popen( “free | grep Swap: | awk ‘{printf $2}’” )
local data = file:read( “*a” )
file:close()
luup.log('Swap total: '…tostring(data) )
if tonumber( data ) == 0
then
os.execute( ‘swapon /tmp/log/cmh/swapfile’ )
end[/code]
--------------------------------------------------------------------------------------[/quote]
I’ve been having problems with memory on my VERALite so I thought I’d try the swapfile route to see if it would help. I copied this code into the Edit Startup Lua and it apparently created the swapfile but it shows the size as ZERO
total used free shared buffers
Mem: 62480 60392 2088 0 1620
Swap: 0 0 0
Total: 62480 60392 2088
As with most things we all want more out of our equipment, and while the Vera 2 was felt to be under spec before. Jumping to Jan 2014 due to the increase in apps the VeraLite for some (maybe many) might benefit of having the swap file there. (Especially if it’s only used when needed, and may advert the odd low memory restart)
As with most things we all want more out of our equipment, and while the Vera 2 was felt to be under spec before. Jumping to Jan 2014 due to the increase in apps the VeraLite for some (maybe many) might benefit of having the swap file there. (Especially if it’s only used when needed, and may advert the odd low memory restart)[/quote]
Its not working, says size is zero.
Apparently there is nothing damaging about the code but it doesn’t create a swapfile. This is one of a number of cases where I have no idea what’s wrong — in the immortal words of Blance DuBois (Streetcar Named Desire) “I have always depended on the kindness of strangers” to tell me what I’ve done wrong ;D
My next step is a newer faster bigger Vera but I’m tempted to wait until the new models come out.
[quote=“parkerc, post:11, topic:171890”]I’m not an expert but I think you have to create your swap file first for it to work, as the code you copy and pasted seems to refer to that file.