Re: [gentoo-user] Memory manager

2019-10-19 Thread Wol's lists

On 19/10/2019 16:24, Mick wrote:
On Saturday, 19 October 2019 14:11:26 bstmad.scientist.at.la...@tutanota.com  
wrote:

Do systems run different memory management when swap is on versus no swap?



The answer to this question is an unqualified yes, although you do not define
your meaning of "different memory management".  The existence of swap space
and the kernel's swappiness setting will change the way memory is dynamically
allocated to processes at runtime and may affect the responsiveness of your
system.


Memory management was massively rewritten roundabout kernel 2.4.

The original swap algorithm NEEDED twice ram as swap. And when Linus 
ripped out all the "optimisation", the vanilla kernels only needed to 
touch swap, and if they didn't have twice ram they would crash.


At that point, the recommendation changed to "no swap is fine, twice or 
more is fine, just don't have swap less than twice ram".


My personal rule is to take the motherboard's max ram, double it, and 
create a swap partition that size on every disk. So my current desktop 
system has 80GB of ram/swap - 4x4GB slots times 2 disk drives. And my 
new system has 4x8GB so that'll be 160GB!!! HOWEVER - Richard Brown of 
SUSE said that's dangerous - if somebody fork-bombs you it'll take a 
long time to fill that much swap and regaining control of your system 
could well be a big red switch job.


Cheers,
Wol



Re: [gentoo-user] Re: syslog-ng 10s pause during startup

2019-10-19 Thread Bill Kenworthy
moriah ~ # esearch haveged
[ Results for search key : haveged ]
[ Applications found : 1 ]

*  sys-apps/haveged
  Latest version available: 1.9.2-r1
  Latest version installed: [ Not Installed ]
  Size of downloaded files: 483 kB
  Homepage:    http://www.issihosts.com/haveged/
  Description: A simple entropy daemon using the HAVEGE algorithm
  License: GPL-3+
 
moriah ~ #




On 19/10/19 10:34 pm, Daniel Frey wrote:
> On 10/18/19 5:47 PM, Grant Edwards wrote:
>> On 2019-10-18, Daniel Frey  wrote:
>>
>>> It is waiting for entropy to build.
>>
>> Interesting -- what does syslog-ng need entropy for?
>>
>>> Moving mouse or typing on keyboard will speed it up but I have
>>> machines only controlled by IR so this was not helpful.
>>
>> Thanks, I'll try that.
>>
>
> I'm not sure actually. I only found it after 15 minutes of
> troubleshooting while noting the time when things started/stopped. I
> came across a log entry with something saying "waiting for entropy"
> and when I noted when boot continued another entry like "entropy
> gathered."
>
> Those aren't the actual log entries but what I "translated" the
> entries to.
>
> Thankfully I wasn't scratching my head for hours over that one. I did
> find if you left it long enough (my IR device would continue boot on
> its own after 20 minutes or so) it would eventually boot.
>
> Waiting 20 minutes for a MythTV appliance to start is pretty silly
> though.
>
> Dan
>
>




Re: [gentoo-user] Memory manager

2019-10-19 Thread Mick
On Saturday, 19 October 2019 14:11:26 BST mad.scientist.at.la...@tutanota.com 
wrote:
> Do systems run different memory management when swap is on versus no swap?

The answer to this question is an unqualified yes, although you do not define 
your meaning of "different memory management".  The existence of swap space 
and the kernel's swappiness setting will change the way memory is dynamically 
allocated to processes at runtime and may affect the responsiveness of your 
system.

However, you may not experience any difference by having swap on, if your 
swappinness setting is low and in addition you never run a high enough number 
of memory hungry processes to consume all available RAM.


> I know that in the past it was recommended to have at least a small swap so
> the system used a better memory manager.  Wondering specifically if I
> should set up a small ram drive for swap just to get better memory
> management or if I should run swapless as this particular machine has a
> slightly obscene amount of ram available so I shouldn't need a proper swap
> partition unless it affects memory management.
> 
> -- “The whole world is watching! The whole world is watching!”

The handbook recommendation to set up a swap space (partition) is probably 
made as a low cost, safe configuration to have, which may even save your bacon 
one day.  It is conceivable you could set portage to run a large enough number 
of jobs on a memory hungry compile, e.g. chromium, to end up with no memory 
left.  In addition, if you tried to Suspend-to-RAM, at a point when all of 
your RAM is being used, you would soon discover you can't do it without any 
swap space made available.  If you hibernate, then a swap space (file/
partition) will be used, which makes it reasonable to have a swap space set up 
for this purpose in advance.  For a desktop, the relative low cost of disk 
space today suggests it is a good idea to set up some swap space, even if you 
hardly ever going to use it.

With the arrival of SSDs the usage of swap was discouraged, because repeated 
read/writes tended to age prematurely the (early) SSDs.  I still use spinning 
disks for swap, but I don't know what the prevailing wisdom/experience suggest 
these days.

Have a look at this for generalities:

https://wiki.gentoo.org/wiki/Knowledge_Base:Is_swap_space_really_necessary


And this for an alternative, or complimentary solution:

https://wiki.gentoo.org/wiki/Zram

-- 
Regards,

Mick

signature.asc
Description: This is a digitally signed message part.


[gentoo-user] Re: syslog-ng 10s pause during startup

2019-10-19 Thread Grant Edwards
On 2019-10-19, Daniel Frey  wrote:
> On 10/18/19 5:47 PM, Grant Edwards wrote:
>> On 2019-10-18, Daniel Frey  wrote:
>> 
>>> It is waiting for entropy to build.
>> 
>> Interesting -- what does syslog-ng need entropy for?
>> 
>>> Moving mouse or typing on keyboard will speed it up but I have
>>> machines only controlled by IR so this was not helpful.
>> 
>> Thanks, I'll try that.

That doesn't seem to make any difference.

> I'm not sure actually. I only found it after 15 minutes of 
> troubleshooting while noting the time when things started/stopped. I 
> came across a log entry with something saying "waiting for entropy" and 
> when I noted when boot continued another entry like "entropy gathered."

Hmm. No messages like that in demsg output.

My next guess would be that the wifi interface isn't up yet, and it's a DNS
lookup timing out.

> Waiting 20 minutes for a MythTV appliance to start is pretty silly though.

Yea, that's definitely beyond the pale.

How's MythTV these days?

I ran Myth for 10+ years, but got frustrated at the lack of a small
cheap silent front-end.

Does the server still refuse to run on a headless machine without X11
and demand that you configure it via a MythTV client on a UI layed out
for a TV?  When I gave up on Myth I switched to SageTV. When Google
bought that and shut it down, I switched to to Plex.  Both SageTV and
Plex can run on a server without X11 can be configured via a web UI.

-- 
Grant




[gentoo-user] Re: New monitor & wine ==> crash

2019-10-19 Thread Hartmut Figge
Mick:

Thanks, Mick.

>I'm not the right person to advise on this problem because I have very limited 
>experience with Nvidia cards and even less with WINE.  Nevertheless, the 
>(generic) way I would go about it would be to try an HDMI cable first in case 
>the higher bitrate makes any difference in what the kernel/driver sees and can 
>drive.

There is indeed a HDMI connector besides the two DVI. A small one,
probably a mini HDMI. The card is several years old and I have forgotten
the specs. The documentation seems to be on a CD. In form of windows
programs. Bah.

The new monitor came with a HDMI cable. I will have to obtain a
mini-HDMI to HDMI cable or an adapter to try.

But I doubt the result will help. Consider that using wine-vanilla-4.01
all resolutions appear as choice in the games.

I have visited WineHQ and subscribed to a forum there, Wine Help. Of
course it is moderated and of course the first three postings need
approval from a moderator. Takes time.

In old times there was a news group with the name wine-user. It was
abandoned years ago in favor of a forum. Grrr.

If there is no improvement, then I would look into feeding a custom
>EDID file for the new monitor to the kernel and see if WINE performance 
>improves.  Have a look at 'xrandr --prop' to see what the new Vs the old 
>monitor display and read this for more:
>
>/usr/src/linux/Documentation/EDID/HOWTO.txt

In the past, long ago, I have played a little with EDID, using the
documentation of Nvidia and the Gentoo package read-edid.

Hartmut




Re: [gentoo-user] Re: syslog-ng 10s pause during startup

2019-10-19 Thread Daniel Frey

On 10/18/19 5:47 PM, Grant Edwards wrote:

On 2019-10-18, Daniel Frey  wrote:


It is waiting for entropy to build.


Interesting -- what does syslog-ng need entropy for?


Moving mouse or typing on keyboard will speed it up but I have
machines only controlled by IR so this was not helpful.


Thanks, I'll try that.



I'm not sure actually. I only found it after 15 minutes of 
troubleshooting while noting the time when things started/stopped. I 
came across a log entry with something saying "waiting for entropy" and 
when I noted when boot continued another entry like "entropy gathered."


Those aren't the actual log entries but what I "translated" the entries to.

Thankfully I wasn't scratching my head for hours over that one. I did 
find if you left it long enough (my IR device would continue boot on its 
own after 20 minutes or so) it would eventually boot.


Waiting 20 minutes for a MythTV appliance to start is pretty silly though.

Dan




[gentoo-user] Memory manager

2019-10-19 Thread mad.scientist.at.large
Do systems run different memory management when swap is on versus no swap?  I 
know that in the past it was recommended to have at least a small swap so the 
system used a better memory manager.  Wondering specifically if I should set up 
a small ram drive for swap just to get better memory management or if I should 
run swapless as this particular machine has a slightly obscene amount of ram 
available so I shouldn't need a proper swap partition unless it affects memory 
management.

-- “The whole world is watching! The whole world is watching!”



Re: [gentoo-user] New monitor & wine ==> crash

2019-10-19 Thread Mick
On Saturday, 19 October 2019 09:11:17 BST Hartmut Figge wrote:
> Greetings,
> 
> I am somewhat desperate. Before I obtained a new monitor, my installed
> games on wine worked fine. Now many of them crash at startup. Most of
> them run still fine under wine-vanilla-4.0.1 but not under
> wine-vanilla-4.17.
> 
> After some tinkering I found a hint when using OblivionLauncher.exe.
> 
> In wine-vanilla-4.0.1 the available resolutions are
> http://www.triffids.de/pub/aoc/wine-4.01_oblivionlauncher.png
> 
> In wine-vanilla-4.17 the available resolutions are
> http://www.triffids.de/pub/aoc/wine-4.17_oblivionlauncher.png
> 
> You can see that most of the resolutions are missing under 4.17. If I
> select the available resolution 800x600 in 4.17 then oblivion starts and
> runs without problems.
> 
> But many of the games do not have a launcher to choose a resolution
> from. I assume when a games tries to start with a resolution which now
> seems unsupported it runs into difficulties.
> 
> So the question is, how to get wine-vanilla-4-17 to accept the available
> resolutions? This problem didn't occur with the old monitor.
> 
> Some info:
> 
> xrandr old monitor:
> Screen 0: minimum 8 x 8, current 1600 x 1200, maximum 16384 x 16384
> DVI-I-0 disconnected primary (normal left inverted right x axis y axis)
> DVI-I-1 connected 1600x1200+0+0 (normal left inverted right x axis y
> axis) 367mm x 275mm
>1600x1200 60.00*+
>1280x1024 75.0260.02
>1152x864  75.00
>1024x768  75.0360.00
>800x600   75.0060.32
>640x480   75.0059.94
> HDMI-0 disconnected (normal left inverted right x axis y axis)
> DVI-D-0 disconnected (normal left inverted right x axis y axis)
> 
> xrandr new monitor
> Screen 0: minimum 8 x 8, current 1920 x 1080, maximum 16384 x 16384
> DVI-I-0 disconnected primary (normal left inverted right x axis y axis)
> DVI-I-1 disconnected (normal left inverted right x axis y axis)
> HDMI-0 disconnected (normal left inverted right x axis y axis)
> DVI-D-0 connected 1920x1080+0+0 (normal left inverted right x axis y
> axis) 725mm x 428mm
>2560x1440 59.95 +
>1920x1080 60.00*
>1680x1050 59.95
>1440x900  59.89
>1280x1440 59.91
>1280x1024 75.0260.02
>1280x960  60.00
>1280x720  60.00
>1024x768  75.0370.0760.00
>800x600   75.0072.1960.3256.25
>720x576   50.00
>720x480   59.94
>640x480   75.0072.8159.94
> 
> nvidia-drivers-435.21
> 
> Hartmut

I'm not the right person to advise on this problem because I have very limited 
experience with Nvidia cards and even less with WINE.  Nevertheless, the 
(generic) way I would go about it would be to try an HDMI cable first in case 
the higher bitrate makes any difference in what the kernel/driver sees and can 
drive.  If there is no improvement, then I would look into feeding a custom 
EDID file for the new monitor to the kernel and see if WINE performance 
improves.  Have a look at 'xrandr --prop' to see what the new Vs the old 
monitor display and read this for more:

/usr/src/linux/Documentation/EDID/HOWTO.txt

HTH.
-- 
Regards,

Mick

signature.asc
Description: This is a digitally signed message part.


[gentoo-user] New monitor & wine ==> crash

2019-10-19 Thread Hartmut Figge
Greetings,

I am somewhat desperate. Before I obtained a new monitor, my installed
games on wine worked fine. Now many of them crash at startup. Most of
them run still fine under wine-vanilla-4.0.1 but not under
wine-vanilla-4.17.

After some tinkering I found a hint when using OblivionLauncher.exe.

In wine-vanilla-4.0.1 the available resolutions are
http://www.triffids.de/pub/aoc/wine-4.01_oblivionlauncher.png

In wine-vanilla-4.17 the available resolutions are
http://www.triffids.de/pub/aoc/wine-4.17_oblivionlauncher.png

You can see that most of the resolutions are missing under 4.17. If I
select the available resolution 800x600 in 4.17 then oblivion starts and
runs without problems.

But many of the games do not have a launcher to choose a resolution
from. I assume when a games tries to start with a resolution which now
seems unsupported it runs into difficulties.

So the question is, how to get wine-vanilla-4-17 to accept the available
resolutions? This problem didn't occur with the old monitor.

Some info:

xrandr old monitor:
Screen 0: minimum 8 x 8, current 1600 x 1200, maximum 16384 x 16384
DVI-I-0 disconnected primary (normal left inverted right x axis y axis)
DVI-I-1 connected 1600x1200+0+0 (normal left inverted right x axis y
axis) 367mm x 275mm
   1600x1200 60.00*+
   1280x1024 75.0260.02
   1152x864  75.00
   1024x768  75.0360.00
   800x600   75.0060.32
   640x480   75.0059.94
HDMI-0 disconnected (normal left inverted right x axis y axis)
DVI-D-0 disconnected (normal left inverted right x axis y axis)

xrandr new monitor
Screen 0: minimum 8 x 8, current 1920 x 1080, maximum 16384 x 16384
DVI-I-0 disconnected primary (normal left inverted right x axis y axis)
DVI-I-1 disconnected (normal left inverted right x axis y axis)
HDMI-0 disconnected (normal left inverted right x axis y axis)
DVI-D-0 connected 1920x1080+0+0 (normal left inverted right x axis y
axis) 725mm x 428mm
   2560x1440 59.95 +
   1920x1080 60.00*
   1680x1050 59.95
   1440x900  59.89
   1280x1440 59.91
   1280x1024 75.0260.02
   1280x960  60.00
   1280x720  60.00
   1024x768  75.0370.0760.00
   800x600   75.0072.1960.3256.25
   720x576   50.00
   720x480   59.94
   640x480   75.0072.8159.94

nvidia-drivers-435.21

Hartmut