Libcurl failed even to execute the HTTP transaction, explaining: Illegal characters found in URL

Hi,

In my environment, I’m trying to to run the sheduler in a separte host but unfortunately I get the following error:

Tue May 28 12:32:48 2019 [Z0][SCHED][E]: Cannot contact oned, will retry... Error: HTTP POST to URL 'http://vdiconeserver1:2633/RPC2
' failed.  libcurl failed even to execute the HTTP transaction, explaining:  Illegal characters found in URL

I’m using the latest version 5.8 and the sched.conf file is the default but the ONE_XMLRPC parameter.

Of course, when I try to execute a curl from my centos 7 host where the scheduler daemon is running, I get the following:

curl http://vdiconeserver1:2633/RPC2
<HTML><HEAD><TITLE>Error 405</TITLE></HEAD><BODY><H1>Error 405</H1><P>POST is the only HTTP method this server understands</P><p><HR><b><i><a href="http://xmlrpc-c.sourceforge.net">ABYSS Web Server for XML-RPC For C/C++</a></i></b> version 1.40.0<br></p></BODY></HTML>

Any clue?
Thanks a lot in advance

Hi everyone,

I have made further investigations and I have found that for any reason It looks mm_sched adds a carry return.

Tue May 28 23:02:29 2019 [Z0][SCHED][E]: Cannot contact oned, will retry... Error: HTTP POST to URL 'http://vdiconeserver1:2633/RPC2^M' failed. libcurl failed even to execute the HTTP transaction, explaining: Illegal characters found in URL

Look at the ^M after RPC2

I have checked sched.conf file and it looks perfectly normal. There is an extraction below:

cat -v /etc/one/sched.conf

#       system_ds_usage = system_ds_usage + memory_system_ds_scale * memory^M
#^M
#*******************************************************************************^M
^M
MESSAGE_SIZE = 1073741824^M
TIMEOUT      = 60^M
^M
ONE_XMLRPC = http://vdiconeserver1:2633/RPC2^M
^M
SCHED_INTERVAL = 30^M

Hi,

Have you edited the file in Windows per chance? Windows uses two characters (0xD 0xA) for carriage return, Linux only one (0xA), 0xD in linux is rendered as ^M.

Getting rid of the ^M characters probably will do the trick.

Hi,

No, the file has been always edited with linux vi.

The appearence of the ^M in the config file is correct in linux because it is the display character of a carry return, nevertheless looks the mm_sched process includes it (the ^M character) in the ONE_XMLRPC url when tries to request one_server.

In the error log the ^M appears and I think it shoudn’t.

cat -v /etc/one/sched.conf

#       system_ds_usage = system_ds_usage + memory_system_ds_scale * memory^M
#^M
#*******************************************************************************^M
^M
MESSAGE_SIZE = 1073741824^M
TIMEOUT      = 60^M
^M
ONE_XMLRPC = http://vdiconeserver1:2633/RPC2^M
^M
SCHED_INTERVAL = 30^M

cat /etc/one/sched.conf (without the -v)

#       system_ds_usage = system_ds_usage + memory_system_ds_scale * memory
#
#*******************************************************************************

MESSAGE_SIZE = 1073741824
TIMEOUT      = 60

ONE_XMLRPC = http://vdiconeserver1:2633/RPC2

SCHED_INTERVAL = 30

I have added the double quotes (as the default):

MESSAGE_SIZE = 1073741824
TIMEOUT      = 60

ONE_XMLRPC = "http://vdiconeserver1:2633/RPC2"

SCHED_INTERVAL = 30

And the log looks like the following:

[oneadmin@93f96d6bdf8d one]$ cat -v sched.log
Wed May 29 16:04:52 2019 [Z0][SCHED][E]: Cannot contact oned, will retry... Error: HTTP POST to URL '"http://vdiconeserver1:2633/RPC2"^M' failed.  libcurl failed even to execute the HTTP transaction, explaining:  Illegal characters found in URL

Anyone has tried to deploy scheduler in a separate host?

If I delete the parameter ONE_XMLRPC from sched.conf in order to force the use of the default value one can see that the ^M has disappeared:

[oneadmin@b06baf5973fb one]$ cat -v sched.log
Wed May 29 16:22:40 2019 [Z0][SCHED][E]: Cannot contact oned, will retry... Error: HTTP POST to URL 'http://localhost:2633/RPC2' failed.  libcurl failed even to execute the HTTP transaction, explaining:  Failed to connect to ::1: Network is unreachable

Thanks a lot.

Hi,

Anyone has run sheduler in another server?

Thanks a lot

Hi everybody,

Anybody has executed scheduler in separate machine? I’d like to know if the issue is in my side or if it is a bug in the product.

Thanks a lot,
Óscar