9 Replies Latest reply: Jan 21, 2013 7:30 AM by Pascal Kreyer -Oracle RSS

    Newbie: how to modify locale settings on a Solaris 10 machine?

    scampsd
      Hello,
      I would like my machine to be able to handle French characters.
      In order to do this, I have asked what are the possible locales on my machine and what are the environment variables that need to be updated in order to modify the locale.

      The answer on the first question contains "fr_BE.ISO8859-15", which is exactly what I want.
      The answer on the second question is the following:
      root#locale
      LANG="C"
      LC_CTYPE="C"
      LC_NUMERIC="C"
      LC_TIME="C"
      LC_COLLATE="C"
      LC_MONETARY="C"
      LC_MESSAGES="C"
      LC_ALL=
      So I have tried to update all those variables into "fr_BE.ISO8859-15", but that failed (only the LANG variable has been updated):
      root#export LC_CTYPE="fr_BE.ISO8859-15"
      ksh: export: couldn't set locale correctly

      root#locale
      LANG=fr_BE.ISO8859-15
      LC_CTYPE="C"
      LC_NUMERIC="C"
      LC_TIME="C"
      LC_COLLATE="C"
      LC_MONETARY="C"
      LC_MESSAGES="C"
      LC_ALL=

      In top of that now I regularly have following error message:
      root#man ls
      Reformatting page. Please Wait...couldn't set locale correctly
      couldn't set locale correctly
      couldn't set locale correctly
      couldn't set locale correctly
      couldn't set locale correctly
      couldn't set locale correctly
      done
      couldn't set locale correctly
      couldn't set locale correctly
      couldn't set locale correctly

      I have been looking into the man pages of "locale" and "localeadm", but there I only find how to install a locale and how to retrieve locale information.

      Do you know what I can do in order to have "fr_BE.ISO8859-15" as locale on my system without having all the mentioned error messages?
      Thanks
      Dominique
        • 1. Re: Newbie: how to modify locale settings on a Solaris 10 machine?
          Pascal Kreyer -Oracle
          The libraries are certainly not installed in /usr/lib/locale.

          Please use this command to install the appropriate packages :

          # localeadm -d <packages location> -a ceu
          • 2. Re: Newbie: how to modify locale settings on a Solaris 10 machine?
            scampsd
            Hello Pascal and thanks for the quick reply.

            However I believe that the locale packages are installed, as you can see:
            root#localeadm -l -q weu
            locale/region name is weu
            Checking for Western Europe region (weu)
            (c_solaris packages)
            |..|
            All packages found.
            Checking for Western Europe region (weu)
            (solaris1 packages)
            |...............|
            All packages found.
            Checking for Western Europe region (weu)
            (solaris2 packages)
            |......|
            All packages found.
            Checking for Western Europe region (weu)
            (solaris3 packages)
            |Checking for Western Europe region (weu)
            (solaris4 packages)
            |Checking for Western Europe region (weu)
            (solaris5 packages)
            |Checking for Western Europe region (weu)
            (langcd1 packages)
            |.............................................|
            All packages found.
            Checking for Western Europe region (weu)
            (langcd2 packages)
            |......|
            All packages found.
            The Western Europe region (weu) is installed on this system without messages
            In only worry about the result "without messages". Does this mean that there is an issue in locale installation anyway?

            Kind regards
            Dominique
            • 3. Re: Newbie: how to modify locale settings on a Solaris 10 machine?
              Pascal Kreyer -Oracle
              This should indicate that the desktop translation messages packages for CDE and Gnome are not installed.
              Not necessary if you don't need CDE and/or Gnome in French.
              • 4. Re: Newbie: how to modify locale settings on a Solaris 10 machine?
                scampsd
                Hello again Pascal,
                I am working on a machine where only Telnet logins and some Java applications are applicable, so there is indeed no need for CDE and/or Gnome.

                This brings us back to the original question: I get a message saying that there is a problem in my locale settings, but the locale administration tool states that there is no problem.

                What can I do now?

                Thanks
                Dominique

                Edited by: scampsd on Jan 11, 2013 5:45 PM
                • 5. Re: Newbie: how to modify locale settings on a Solaris 10 machine?
                  Pascal Kreyer -Oracle
                  Check in /usr/lib/locale if a directory with the locale name exists and if any files exist in this one.
                  • 6. Re: Newbie: how to modify locale settings on a Solaris 10 machine?
                    scampsd
                    Sorry for the delay.
                    Yes, there are files in the mentioned directory:
                    root# pwd
                    /usr/lib/locale
                    root# ls -ltra | grep fr_BE
                    drwxr-xr-x   3 root     bin          512 Dec 20 03:08 fr_BE
                    drwxr-xr-x   3 root     bin          512 Dec 20 03:08 fr_BE.UTF-8
                    drwxr-xr-x   3 root     bin          512 Dec 20 03:08 fr_BE.ISO8859-15
                    root# cd fr_BE.ISO8859-15/
                    root# ls -ltra
                    total 10
                    drwxr-xr-x   2 bin      bin          512 Feb 15  2011 LC_MESSAGES
                    drwxr-xr-x   3 root     bin          512 Dec 20 03:08 .
                    drwxr-xr-x 106 root     bin         3072 Dec 20 03:53 ..
                    root# cd LC_MESSAGES/
                    root# ls -ltra
                    total 6
                    lrwxrwxrwx   1 root     other         38 Feb 15  2011 amq.cat -> /usr/lib/locale/fr/LC_MESSAGES/amq.cat
                    drwxr-xr-x   2 bin      bin          512 Feb 15  2011 .
                    drwxr-xr-x   3 root     bin          512 Dec 20 03:08 ..
                    I have watched the mentioned "amq.cat" file, it contains some extremely long French sentences :-) (629168 characters on 16 lines).

                    Is this helpful?
                    Dominique
                    • 7. Re: Newbie: how to modify locale settings on a Solaris 10 machine?
                      Pascal Kreyer -Oracle
                      This locale is incomplete.

                      Please run this command and check if something change :

                      # localeadm -d <media location> -a fr_BE
                      • 8. Re: Newbie: how to modify locale settings on a Solaris 10 machine?
                        scampsd
                        Good afternoon Pascal,
                        We have tried the command that you proposed, but it seems not to work:
                        root#localeadm -d /mnt/Solaris_10/Product/ -a fr_FR
                        Log file is /var/sadm/install/logs/localeadmin_install.2013-01-22.6
                        
                        locale/region name is fr_fr
                        
                        Warning! You have chosen the fr_FR locale rather than a region to install.
                        This locale is part of the Western Europe region. If you choose to continue, all of the locales in this region will be installed.
                        
                        Do you wish to continue? [y/n]: y
                        Adding packages for Western Europe (weu)
                        
                        Region weu is already installed on this machine. Exiting
                        While verifying corresponding directory, we can see:
                        root#pwd
                        /usr/lib/locale/fr_FR.UTF-8/LC_MESSAGES
                        root#ls -ltra
                        total 6
                        lrwxrwxrwx   1 root     other         38 Feb 15  2011 amq.cat -> /usr/lib/locale/fr/LC_MESSAGES/amq.cat
                        drwxr-xr-x   2 bin      bin          512 Feb 15  2011 .
                        drwxr-xr-x   3 root     bin          512 Dec 20 03:08 ..
                        (In my previous postings I have mistaken between fr_BE and fr_FR)
                        Do you have any proposals on how to continue?
                        Thanks
                        Dominique
                        • 9. Re: Newbie: how to modify locale settings on a Solaris 10 machine?
                          Pascal Kreyer -Oracle
                          I will suggest to open a service request for this issue. We need to check a little more on your configuration to check what is wrong.