Unknown locale UTF-8 when installing MsSQL server on ubuntu
I'm trying to install Ms SQL Server
on ubuntu 17.10
, I run commands step by step:
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
sudo add-apt-repository "$(wget -qO- https://packages.microsoft.com/config/ubuntu/16.04/mssql-server-2017.list)"
sudo apt-get update
sudo apt-get install -y mssql-server
and when I run setup command:
sudo /opt/mssql/bin/mssql-conf setup
I get the following error:
Traceback (most recent call last):
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 277, in <module>
main()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 273, in main
processCommands()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 197, in processCommands
COMMAND_TABLE[args.which]()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 54, in handleSetup
exit(mssqlconfhelper.setupSqlServer(eulaAccepted, noprompt=args.noprompt))
File "/opt/mssql/lib/mssql-conf/mssqlconfhelper.py", line 817, in setupSqlServer
languageSelect(noprompt)
File "/opt/mssql/lib/mssql-conf/mssqlconfhelper.py", line 160, in languageSelect
language = locale.getdefaultlocale()[0]
File "/usr/lib/python2.7/locale.py", line 545, in getdefaultlocale
return _parse_localename(localename)
File "/usr/lib/python2.7/locale.py", line 477, in _parse_localename
raise ValueError, 'unknown locale: %s' % localename
ValueError: unknown locale: UTF-8
locale
command outputs:
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=C.UTF-8
LANGUAGE=
LC_CTYPE=UTF-8
LC_NUMERIC="C.UTF-8"
LC_TIME="C.UTF-8"
LC_COLLATE="C.UTF-8"
LC_MONETARY="C.UTF-8"
LC_MESSAGES="C.UTF-8"
LC_PAPER="C.UTF-8"
LC_NAME="C.UTF-8"
LC_ADDRESS="C.UTF-8"
LC_TELEPHONE="C.UTF-8"
LC_MEASUREMENT="C.UTF-8"
LC_IDENTIFICATION="C.UTF-8"
LC_ALL=
root@ubuntu-mssql-server:~#
what might be the solution?
python locale mssql
|
show 1 more comment
I'm trying to install Ms SQL Server
on ubuntu 17.10
, I run commands step by step:
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
sudo add-apt-repository "$(wget -qO- https://packages.microsoft.com/config/ubuntu/16.04/mssql-server-2017.list)"
sudo apt-get update
sudo apt-get install -y mssql-server
and when I run setup command:
sudo /opt/mssql/bin/mssql-conf setup
I get the following error:
Traceback (most recent call last):
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 277, in <module>
main()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 273, in main
processCommands()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 197, in processCommands
COMMAND_TABLE[args.which]()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 54, in handleSetup
exit(mssqlconfhelper.setupSqlServer(eulaAccepted, noprompt=args.noprompt))
File "/opt/mssql/lib/mssql-conf/mssqlconfhelper.py", line 817, in setupSqlServer
languageSelect(noprompt)
File "/opt/mssql/lib/mssql-conf/mssqlconfhelper.py", line 160, in languageSelect
language = locale.getdefaultlocale()[0]
File "/usr/lib/python2.7/locale.py", line 545, in getdefaultlocale
return _parse_localename(localename)
File "/usr/lib/python2.7/locale.py", line 477, in _parse_localename
raise ValueError, 'unknown locale: %s' % localename
ValueError: unknown locale: UTF-8
locale
command outputs:
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=C.UTF-8
LANGUAGE=
LC_CTYPE=UTF-8
LC_NUMERIC="C.UTF-8"
LC_TIME="C.UTF-8"
LC_COLLATE="C.UTF-8"
LC_MONETARY="C.UTF-8"
LC_MESSAGES="C.UTF-8"
LC_PAPER="C.UTF-8"
LC_NAME="C.UTF-8"
LC_ADDRESS="C.UTF-8"
LC_TELEPHONE="C.UTF-8"
LC_MEASUREMENT="C.UTF-8"
LC_IDENTIFICATION="C.UTF-8"
LC_ALL=
root@ubuntu-mssql-server:~#
what might be the solution?
python locale mssql
Do you log in to the server from a macOS machine?
– Gunnar Hjalmarsson
Jan 14 '18 at 1:48
@gunnar yes, I'm logging from macos terminal using ssh
– Arkadi
Jan 14 '18 at 7:33
Ok.UTF-8
is an invalid locale name on Ubuntu, and probably you export a locale variable to that name when logging in. Does possibly the file~/.ssh/environment
exist which sets some locale variable toUTF-8
?
– Gunnar Hjalmarsson
Jan 14 '18 at 10:33
There's no dir ~/.ssh/environment
– Arkadi
Jan 14 '18 at 11:33
Then can you please show us the output of thelocale
command (by editing your question).
– Gunnar Hjalmarsson
Jan 14 '18 at 11:39
|
show 1 more comment
I'm trying to install Ms SQL Server
on ubuntu 17.10
, I run commands step by step:
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
sudo add-apt-repository "$(wget -qO- https://packages.microsoft.com/config/ubuntu/16.04/mssql-server-2017.list)"
sudo apt-get update
sudo apt-get install -y mssql-server
and when I run setup command:
sudo /opt/mssql/bin/mssql-conf setup
I get the following error:
Traceback (most recent call last):
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 277, in <module>
main()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 273, in main
processCommands()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 197, in processCommands
COMMAND_TABLE[args.which]()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 54, in handleSetup
exit(mssqlconfhelper.setupSqlServer(eulaAccepted, noprompt=args.noprompt))
File "/opt/mssql/lib/mssql-conf/mssqlconfhelper.py", line 817, in setupSqlServer
languageSelect(noprompt)
File "/opt/mssql/lib/mssql-conf/mssqlconfhelper.py", line 160, in languageSelect
language = locale.getdefaultlocale()[0]
File "/usr/lib/python2.7/locale.py", line 545, in getdefaultlocale
return _parse_localename(localename)
File "/usr/lib/python2.7/locale.py", line 477, in _parse_localename
raise ValueError, 'unknown locale: %s' % localename
ValueError: unknown locale: UTF-8
locale
command outputs:
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=C.UTF-8
LANGUAGE=
LC_CTYPE=UTF-8
LC_NUMERIC="C.UTF-8"
LC_TIME="C.UTF-8"
LC_COLLATE="C.UTF-8"
LC_MONETARY="C.UTF-8"
LC_MESSAGES="C.UTF-8"
LC_PAPER="C.UTF-8"
LC_NAME="C.UTF-8"
LC_ADDRESS="C.UTF-8"
LC_TELEPHONE="C.UTF-8"
LC_MEASUREMENT="C.UTF-8"
LC_IDENTIFICATION="C.UTF-8"
LC_ALL=
root@ubuntu-mssql-server:~#
what might be the solution?
python locale mssql
I'm trying to install Ms SQL Server
on ubuntu 17.10
, I run commands step by step:
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
sudo add-apt-repository "$(wget -qO- https://packages.microsoft.com/config/ubuntu/16.04/mssql-server-2017.list)"
sudo apt-get update
sudo apt-get install -y mssql-server
and when I run setup command:
sudo /opt/mssql/bin/mssql-conf setup
I get the following error:
Traceback (most recent call last):
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 277, in <module>
main()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 273, in main
processCommands()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 197, in processCommands
COMMAND_TABLE[args.which]()
File "/opt/mssql/bin/../lib/mssql-conf/mssql-conf.py", line 54, in handleSetup
exit(mssqlconfhelper.setupSqlServer(eulaAccepted, noprompt=args.noprompt))
File "/opt/mssql/lib/mssql-conf/mssqlconfhelper.py", line 817, in setupSqlServer
languageSelect(noprompt)
File "/opt/mssql/lib/mssql-conf/mssqlconfhelper.py", line 160, in languageSelect
language = locale.getdefaultlocale()[0]
File "/usr/lib/python2.7/locale.py", line 545, in getdefaultlocale
return _parse_localename(localename)
File "/usr/lib/python2.7/locale.py", line 477, in _parse_localename
raise ValueError, 'unknown locale: %s' % localename
ValueError: unknown locale: UTF-8
locale
command outputs:
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=C.UTF-8
LANGUAGE=
LC_CTYPE=UTF-8
LC_NUMERIC="C.UTF-8"
LC_TIME="C.UTF-8"
LC_COLLATE="C.UTF-8"
LC_MONETARY="C.UTF-8"
LC_MESSAGES="C.UTF-8"
LC_PAPER="C.UTF-8"
LC_NAME="C.UTF-8"
LC_ADDRESS="C.UTF-8"
LC_TELEPHONE="C.UTF-8"
LC_MEASUREMENT="C.UTF-8"
LC_IDENTIFICATION="C.UTF-8"
LC_ALL=
root@ubuntu-mssql-server:~#
what might be the solution?
python locale mssql
python locale mssql
edited Jan 14 '18 at 12:24
Arkadi
asked Jan 13 '18 at 18:58
ArkadiArkadi
13417
13417
Do you log in to the server from a macOS machine?
– Gunnar Hjalmarsson
Jan 14 '18 at 1:48
@gunnar yes, I'm logging from macos terminal using ssh
– Arkadi
Jan 14 '18 at 7:33
Ok.UTF-8
is an invalid locale name on Ubuntu, and probably you export a locale variable to that name when logging in. Does possibly the file~/.ssh/environment
exist which sets some locale variable toUTF-8
?
– Gunnar Hjalmarsson
Jan 14 '18 at 10:33
There's no dir ~/.ssh/environment
– Arkadi
Jan 14 '18 at 11:33
Then can you please show us the output of thelocale
command (by editing your question).
– Gunnar Hjalmarsson
Jan 14 '18 at 11:39
|
show 1 more comment
Do you log in to the server from a macOS machine?
– Gunnar Hjalmarsson
Jan 14 '18 at 1:48
@gunnar yes, I'm logging from macos terminal using ssh
– Arkadi
Jan 14 '18 at 7:33
Ok.UTF-8
is an invalid locale name on Ubuntu, and probably you export a locale variable to that name when logging in. Does possibly the file~/.ssh/environment
exist which sets some locale variable toUTF-8
?
– Gunnar Hjalmarsson
Jan 14 '18 at 10:33
There's no dir ~/.ssh/environment
– Arkadi
Jan 14 '18 at 11:33
Then can you please show us the output of thelocale
command (by editing your question).
– Gunnar Hjalmarsson
Jan 14 '18 at 11:39
Do you log in to the server from a macOS machine?
– Gunnar Hjalmarsson
Jan 14 '18 at 1:48
Do you log in to the server from a macOS machine?
– Gunnar Hjalmarsson
Jan 14 '18 at 1:48
@gunnar yes, I'm logging from macos terminal using ssh
– Arkadi
Jan 14 '18 at 7:33
@gunnar yes, I'm logging from macos terminal using ssh
– Arkadi
Jan 14 '18 at 7:33
Ok.
UTF-8
is an invalid locale name on Ubuntu, and probably you export a locale variable to that name when logging in. Does possibly the file ~/.ssh/environment
exist which sets some locale variable to UTF-8
?– Gunnar Hjalmarsson
Jan 14 '18 at 10:33
Ok.
UTF-8
is an invalid locale name on Ubuntu, and probably you export a locale variable to that name when logging in. Does possibly the file ~/.ssh/environment
exist which sets some locale variable to UTF-8
?– Gunnar Hjalmarsson
Jan 14 '18 at 10:33
There's no dir ~/.ssh/environment
– Arkadi
Jan 14 '18 at 11:33
There's no dir ~/.ssh/environment
– Arkadi
Jan 14 '18 at 11:33
Then can you please show us the output of the
locale
command (by editing your question).– Gunnar Hjalmarsson
Jan 14 '18 at 11:39
Then can you please show us the output of the
locale
command (by editing your question).– Gunnar Hjalmarsson
Jan 14 '18 at 11:39
|
show 1 more comment
2 Answers
2
active
oldest
votes
As a workaround I suggest that you open the ~/.profile
file for editing and add the line:
unset LC_CTYPE
That ought to compensate for the issue.
add a comment |
Reading from other forums I found that if you change the local variable named "LC_ALL", it has to be set to the following value: en_US.UTF-8
.
The way to do this is to execute the following command as root:
export LC_ALL=en_US.UTF-8
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f995583%2funknown-locale-utf-8-when-installing-mssql-server-on-ubuntu%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
As a workaround I suggest that you open the ~/.profile
file for editing and add the line:
unset LC_CTYPE
That ought to compensate for the issue.
add a comment |
As a workaround I suggest that you open the ~/.profile
file for editing and add the line:
unset LC_CTYPE
That ought to compensate for the issue.
add a comment |
As a workaround I suggest that you open the ~/.profile
file for editing and add the line:
unset LC_CTYPE
That ought to compensate for the issue.
As a workaround I suggest that you open the ~/.profile
file for editing and add the line:
unset LC_CTYPE
That ought to compensate for the issue.
answered Jan 14 '18 at 13:32
Gunnar HjalmarssonGunnar Hjalmarsson
19.4k23461
19.4k23461
add a comment |
add a comment |
Reading from other forums I found that if you change the local variable named "LC_ALL", it has to be set to the following value: en_US.UTF-8
.
The way to do this is to execute the following command as root:
export LC_ALL=en_US.UTF-8
add a comment |
Reading from other forums I found that if you change the local variable named "LC_ALL", it has to be set to the following value: en_US.UTF-8
.
The way to do this is to execute the following command as root:
export LC_ALL=en_US.UTF-8
add a comment |
Reading from other forums I found that if you change the local variable named "LC_ALL", it has to be set to the following value: en_US.UTF-8
.
The way to do this is to execute the following command as root:
export LC_ALL=en_US.UTF-8
Reading from other forums I found that if you change the local variable named "LC_ALL", it has to be set to the following value: en_US.UTF-8
.
The way to do this is to execute the following command as root:
export LC_ALL=en_US.UTF-8
edited Oct 30 '18 at 20:23
zx485
1,47131115
1,47131115
answered Oct 30 '18 at 19:17
Nicolas HernandezNicolas Hernandez
163
163
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f995583%2funknown-locale-utf-8-when-installing-mssql-server-on-ubuntu%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Do you log in to the server from a macOS machine?
– Gunnar Hjalmarsson
Jan 14 '18 at 1:48
@gunnar yes, I'm logging from macos terminal using ssh
– Arkadi
Jan 14 '18 at 7:33
Ok.
UTF-8
is an invalid locale name on Ubuntu, and probably you export a locale variable to that name when logging in. Does possibly the file~/.ssh/environment
exist which sets some locale variable toUTF-8
?– Gunnar Hjalmarsson
Jan 14 '18 at 10:33
There's no dir ~/.ssh/environment
– Arkadi
Jan 14 '18 at 11:33
Then can you please show us the output of the
locale
command (by editing your question).– Gunnar Hjalmarsson
Jan 14 '18 at 11:39