Cannot create pidfile /var/run/haproxy

Ubuntu 18.04.6 LTS (32bit)

The following occurs when starting haproxy:

[WARNING] 349/103025 (11368) : Setting tune.ssl.default-dh-param to 1024 by default, if your workload permits it you should set it to at least 2048. Please set a value >= 1024 to make this warning disappear.
[ALERT] 349/103025 (11368) : [/usr/sbin/haproxy.main()] Cannot create pidfile /var/run/haproxy

/var/run-> /run
/run/haproxy/admin.sock exists after invocation of the above haproxy. Removing the socket prior to the invocation doesn’t help either.

Is the ownership and mode ok?:
ls -ld /run/haproxy
# drwxrwsr-x 2 haproxy haproxy 40 Dec 16 10:42 haproxy/

And what to do about the tune.ssl.default-dh-param?

Solved both.

For one, the start issue (cannot create pidfile) was due to the fact that the command line invocation will run haproxy as root while haproxy will be running as user haproxy.

service haproxy start the worked.

For the other issue ([WARNING] 349/103025 (11368) : Setting tune.ssl.default-dh-param to 1024 by default, if your workload permits it you should set it to at least 2048. Please set a value >= 1024 to make this warning disappear.
I found a remedy here.