Support #15532
closedCould not evaluate: Proxy myinternal.hostname.com cannot be registered ("\xE2" on US-ASCII): N/A
Description
I am getting following error while install foreman
/Stage[main]/Foreman_proxy::Register/Foreman_smartproxy[myinternal.hostname.com]: Could not evaluate: Proxy myinternal.hostname.com cannot be registered ("\xE2" on US-ASCII): N/A
Where as my "myinternal.hostname.com" is my hostname. I have a DNS entry in my local DNS server as well as /etc/hosts entry
$ cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
#::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.50.202 myinternal.hostname.com myinternal
forman.log from installer log shows
[ INFO 2016-06-28 09:03:34 main] All hooks in group post finished
[DEBUG 2016-06-28 09:03:34 main] Exit with status code: 4 (signal was 4)
[ERROR 2016-06-28 09:03:34 main] Errors encountered during run:
[ERROR 2016-06-28 09:03:34 main] /Stage[main]/Foreman_proxy::Register/Foreman_smartproxy[myinternal.hostname.com]: Could not evaluate: Proxy myinternal.hostname.com cannot be registered ("\xE2" on US-ASCII): N/A
[DEBUG 2016-06-28 09:03:34 main] Cleaning /tmp/d20160628-13417-j709vt
[DEBUG 2016-06-28 09:03:34 main] Cleaning /tmp/default_values.yaml
Updated by Javad Shareef almost 8 years ago
I am in CentOS 7
I was following https://theforeman.org/manuals/1.11/index.html#3.InstallingForeman
Updated by Dominic Cleal almost 8 years ago
Is the Foreman web UI and installation itself working, with the exception of the smart proxy? Did you pass any arguments or change installer parameters from the defaults?
Updated by Javad Shareef almost 8 years ago
Dominic Cleal wrote:
Is the Foreman web UI and installation itself working, with the exception of the smart proxy? Did you pass any arguments or change installer parameters from the defaults?
Yes. Web UI is working. Getting this output after installation and foreman web UI is loading.
/Stage[main]/Foreman_proxy::Register/Foreman_smartproxy[myinternal.hostname.com]: Could not evaluate: Proxy myinternal.hostname.com cannot be registered ("\xE2" on US-ASCII): N/A
Installing Done [100%] [...............................................................................]
Something went wrong! Check the log for ERROR-level output
* Foreman is running at https://myinternal.hostname.com
Initial credentials are admin / <random-password>
* Foreman Proxy is running at https://myinternal.hostname.com:8443
* Puppetmaster is running at port 8140
The full log is at /var/log/foreman-installer/foreman.log
netstat output is
- netstat -tupln
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:46318 0.0.0.0:* LISTEN 2119/Passenger Rack
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 798/sshd
tcp 0 0 127.0.0.1:5432 0.0.0.0:* LISTEN 897/postgres
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 1325/master
tcp 0 0 0.0.0.0:8443 0.0.0.0:* LISTEN 2075/ruby
tcp 0 0 127.0.0.1:54496 0.0.0.0:* LISTEN 2478/Passenger Rack
tcp6 0 0 :::8140 :::* LISTEN 814/httpd
tcp6 0 0 :::80 :::* LISTEN 814/httpd
tcp6 0 0 :::22 :::* LISTEN 798/sshd
tcp6 0 0 ::1:5432 :::* LISTEN 897/postgres
tcp6 0 0 ::1:25 :::* LISTEN 1325/master
tcp6 0 0 :::443 :::* LISTEN 814/httpd
udp 0 0 0.0.0.0:69 0.0.0.0:* 847/xinetd
Also when I do puppet agent test getting following error
- puppet agent --test
Warning: Unable to fetch my node definition, but the agent run will continue:
Warning: Error 400 on SERVER: Failed to find myinternal.hostname.com via exec: Execution of '/etc/puppet/node.rb myinternal.hostname.com' returned 1:
Info: Retrieving pluginfacts
Info: Retrieving plugin
Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Failed when searching for node myinternal.hostname.com: Failed to find myinternal.hostname.com via exec: Execution of '/etc/puppet/node.rb myinternal.hostname.com' returned 1:
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run
Updated by Javad Shareef almost 8 years ago
I didn't pass any arguments with the installer command.
- foreman-installer
Firewalld and selinux is disabled on the server
Updated by Dominic Cleal almost 8 years ago
What does echo $LANG
output in your shell?
Updated by Ewoud Kohl van Wijngaarden almost 8 years ago
I wonder what's in /var/log/foreman/production.log. Usually that has more information. However, I suspect that there's a hidden unicode character somewhere in your hostname.
Updated by Javad Shareef almost 8 years ago
Dominic Cleal wrote:
What does
echo $LANG
output in your shell?
- echo $LANG
en_US.UTF-8
Updated by Javad Shareef almost 8 years ago
Ewoud Kohl van Wijngaarden wrote:
I wonder what's in /var/log/foreman/production.log. Usually that has more information. However, I suspect that there's a hidden unicode character somewhere in your hostname.
I have following logs in production.log
2016-06-28 10:04:54 [app] [I] Completed 403 Forbidden in 10ms (ActiveRecord: 0.9ms)
2016-06-28 10:04:54 [app] [I] Started POST "/api/reports" for 127.0.0.1 at 2016-06-28 10:04:54 -0400
2016-06-28 10:04:54 [app] [I] Processing by Api::V2::ReportsController#create as JSON
2016-06-28 10:04:54 [app] [I] Parameters: {"report"=>"[FILTERED]", "apiv"=>"v2"}
2016-06-28 10:04:54 [app] [W] No smart proxy server found on ["myinternal.hostname.com", "puppet", "puppet.hostname.com"] and is not in trusted_puppetmaster_hosts
2016-06-28 10:04:54 [app] [I] Rendered api/v2/errors/access_denied.json.rabl within api/v2/layouts/error_layout (0.9ms)
2016-06-28 10:04:54 [app] [I] Filter chain halted as #<Proc:0x000000054c29a8@/usr/share/foreman/app/controllers/concerns/foreman/controller/smart_proxy_auth.rb:14> rendered or redirected
Updated by Javad Shareef almost 8 years ago
Ewoud Kohl van Wijngaarden wrote:
I wonder what's in /var/log/foreman/production.log. Usually that has more information. However, I suspect that there's a hidden unicode character somewhere in your hostname.
I checked hidden char in hostname as follows
printf "%s" "$host_name" | wc
0 1 26
Which gives the same length as my hostname
Updated by Javad Shareef almost 8 years ago
Javad Shareef wrote:
Ewoud Kohl van Wijngaarden wrote:
I wonder what's in /var/log/foreman/production.log. Usually that has more information. However, I suspect that there's a hidden unicode character somewhere in your hostname.
I checked hidden char in hostname as follows
printf "%s" "$host_name" | wc
0 1 26Which gives the same length as my hostname
At last found the issue. The issue was with charset. I have fixed by running following command
localedef -c -f UTF-8 -i en_US en_US.UTF-8
export LC_ALL=en_US.UTF-8
Also added entry in /etc/environment as follows
export LC_ALL=en_US.UTF-8
Then rebooted the machine.
Later everything went well... Hureyy.....
Updated by Daniel Lobato Garcia almost 8 years ago
- Tracker changed from Bug to Support
- Status changed from New to Resolved