Status: New
Owner: ----
New issue 279 by [email protected]: Special characters (non-ASCII) not
supported in instances OS field
http://code.google.com/p/ganeti/issues/detail?id=279
What software version are you running? Please provide the output of "gnt-
cluster --version" and "gnt-cluster version".
# gnt-cluster version
Software version: 2.5.1
Internode protocol: 2050000
Configuration format: 2050000
OS api version: 20
Export interface: 0
# gnt-cluster --version
gnt-cluster (ganeti v2.5.1) 2.5.1
What distribution are you using?
# cat /etc/debian_version
6.0.6
# uname -a
Linux shelley.oehwu.local 2.6.32-5-amd64 #1 SMP Sun May 6 04:00:17 UTC 2012
x86_64 GNU/Linux
What steps will reproduce the problem?
1. Rename an instance with gnt-instance --force --force-variant -o "some
name with special character" [instance_name]
What is the expected output? What do you see instead?
When creating an instance in fully virualized mode and installing the OS
with it's install CD, some people (like me) abuse the OS field to add a
small description. The use of a special character like german "Umlaute" (ä,
ö, ü) every time when showing the OS field (gnt-instance list, gnt-instance
info) ganeti throws some kind of unicode error:
# gnt-instance list
Traceback (most recent call last):
File "/usr/sbin/gnt-instance", line 21, in <module>
sys.exit(main.Main())
File "/usr/lib/pymodules/python2.6/ganeti/client/gnt_instance.py", line
1556, in Main
override={"tag_type": constants.TAG_INSTANCE})
File "/usr/lib/pymodules/python2.6/ganeti/cli.py", line 2025, in
GenericMain
result = func(options, args)
File "/usr/lib/pymodules/python2.6/ganeti/client/gnt_instance.py", line
223, in ListInstances
force_filter=opts.force_filter)
File "/usr/lib/pymodules/python2.6/ganeti/cli.py", line 2676, in
GenericList
verbose=verbose)
File "/usr/lib/pymodules/python2.6/ganeti/cli.py", line 2590, in
FormatQueryResult
table = FormatTable(result.data, columns, header, separator)
File "/usr/lib/pymodules/python2.6/ganeti/cli.py", line 2786, in
FormatTable
formatted = [col.format(value) for value, col in zip(row, columns)]
File "/usr/lib/pymodules/python2.6/ganeti/cli.py", line 2517, in __call__
return self._fn(value)
UnicodeEncodeError: 'ascii' codec can't encode character u'\xd6' in
position 25: ordinal not in range(128)
The solution to repair this is editing the config.data file by hand and
removing the umlaut.
Please provide any additional information below.
Accorting to Iustin this is a known bug on the internal bug tracker,
related to Python 2.x
The corresponding discussion can be found here:
https://groups.google.com/d/topic/ganeti/UMmW6ZJfgaw/discussion