This discussion is archived
2 Replies Latest reply: Dec 18, 2008 3:33 PM by 807574 RSS

How to change portal parameters with command line?

807574 Newbie
Currently Being Moderated
Hello all,

After Sun JES installation I'm changed few parameters in amconsole as amadmin.

1. "Service Configuration" -> "Portal Desktop" -> "Authentication-less Portal Desktop Configuration"
Select as "Disable"

2. "Service Configuration" -> "Globalization Settings" -> "Charsets Supported by Each Locale"
Add locale "locale=ru|charset=UTF-8;ISO-8859-1"

Is it possible to do it from command line?

I think it should be amadmin command...

Thanks
  • 1. Re: How to change portal parameters with command line?
    793920 Newbie
    Currently Being Moderated
    For the locale, it's with amadmin command (amadmin -u amadinuserdn -w password -t file.xml).

    The xml you must use look like this:
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <!DOCTYPE Requests
        PUBLIC "-//iPlanet//Sun Java System Access Manager 2005Q4 Admin CLI DTD//EN"
        "jar://com/iplanet/am/admin/cli/amAdmin.dtd"
    >
    <Requests>
            <SchemaRequests serviceName="iPlanetG11NSettings" SchemaType="global">
                    <AddDefaultValues>
                            <AttributeValuePair>
                                    <Attribute name="sun-identity-g11n-settings-locale-charset-mapping"/>
                                    <Value>locale=ru|charset=UTF-8;ISO-8859-1</Value>
                            </AttributeValuePair>
                    </AddDefaultValues>
            </SchemaRequests>
    </Requests>
    If the xml is not correct, look into /etc/opt/SUNWam/config/xml. You should find the exact service definition for the globalization settings.

    Vincent

    Edited by: vvlier on Dec 18, 2008 11:15 AM
  • 2. Re: How to change portal parameters with command line?
    807574 Newbie
    Currently Being Moderated
    Hello Vincent,

    Thanks for your reply, you very helped me with my problem.

    As result I created the following xml file
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <!--
        Copyright (c) 2005 Sun Microsystems, Inc. All rights reserved
        Use is subject to license terms.
    -->
    
    <!DOCTYPE Requests
        PUBLIC "-//iPlanet//Sun Java System Access Manager 2005Q4 Admin CLI DTD//EN"
        "jar://com/iplanet/am/admin/cli/amAdmin.dtd"
        >
    
    <!--  Modify REQUESTS -->
    
    <Requests>
        <SchemaRequests serviceName="iPlanetG11NSettings" SchemaType="global">
            <AddDefaultValues>
                <AttributeValuePair>
                    <Attribute name="sun-identity-g11n-settings-locale-charset-mapping"/>
                    <Value>locale=ru|charset=UTF-8;ISO-8859-1</Value>
                </AttributeValuePair>
            </AddDefaultValues>
        </SchemaRequests>
    
        <SchemaRequests serviceName="SunPortalDesktopService" SchemaType="global">
            <ModifyDefaultValues>
                <AttributeValuePair>
                    <Attribute name="sunPortalDesktopEnableAuthlessDesktop"/>
                    <Value>false</Value>
                </AttributeValuePair>
            </ModifyDefaultValues>
        </SchemaRequests>
    </Requests>
    I found only one way how to find certain attribute in service for work from command line with XML file.
    1. Open Sun Java System Server Console
    2. Open Directory Server in that console.
    3. In root domain tree expand "services"
    4. Select certain service at the left part of the console and double click in the right part for selected service.
    5. Investigate XML text in service attribute "sunserviceschema".

    I don't know another way how to search service attributes. :)

    Best.