Results 1 to 5 of 5
  1. #1
    Join Date
    Mar 2007
    Posts
    167

    Unanswered: Can I manually modify suid in syslogins?

    We have installed a new development server (ASE 12.5.4) and want to migrate some of the logins to the new server from Production (also ASE 12.5.4).

    I was thinking of using BCP to do this. The challenge though... The new development server already has existing logins, which already occupy the suid we want to use from Production.

    Can I safely manually modify the suid on the development server to higher numbers? For example... the new server logins are using suid 5 - 10, can I mannually modify them to a higher number (15 - 20)? Then BCP in the production logins which occupy suid 5 - 10?

    What are your thoughts?

    Thank you.

  2. #2
    Join Date
    Feb 2002
    Location
    Willy is on vacation
    Posts
    1,208
    No. Sybase relies on concrete identification. This will completely screw up the server.

    Before you start, ensure that 'sa' is unlocked. Instead you should purge anything that is not in 'sa' and sync syslogins, sysloginroles, syssrvroles, sysattributes.object_type='UR'.

  3. #3
    Join Date
    Mar 2007
    Posts
    167

    Do I need to reinstall ASE now?

    Unfortunetly before I saw your response, I did the following...

    ----------------------------------------------------------------
    1) Confirmed the SUIDs in syslogins
    ----------------------------------------------------------------
    select suid, dbname, name, fullname from syslogins
    go

    suid dbname name fullname
    ------- ----------- ---------- ---------------
    1 master sa (null)
    2 sybsystemdb probe (null)
    6 master sa_dbateam User Name01
    7 master sa_appteam User Name02
    8 master dbo_appteam User Name 03
    ----------------------------------------------------------------


    ----------------------------------------------------------------
    2) Confirmed the SUIDs in sysloginroles
    ----------------------------------------------------------------
    select * from sysloginroles
    go

    suid srid status
    ------- ------- ---------
    1 0 1
    1 1 1
    1 2 1
    1 3 1
    6 0 1
    6 1 1
    6 2 1
    6 3 1
    7 0 1
    7 1 1
    7 2 1
    7 3 1
    ----------------------------------------------------------------


    ----------------------------------------------------------------
    3) Changed the SUIDs in syslogins
    ----------------------------------------------------------------
    sp_configure 'allow updates to system tables', 1
    go

    update syslogins set suid = 16 where suid = 6
    go

    update sysloginroles set suid = 17 where suid = 7
    go

    update sysloginroles set suid = 18 where suid = 8
    go

    sp_configure 'allow updates to system tables', 0
    go
    ----------------------------------------------------------------


    ----------------------------------------------------------------
    4) Changed the SUIDs in sysloginroles
    ----------------------------------------------------------------
    sp_configure 'allow updates to system tables', 1
    go

    update syslogins set suid = 16 where suid = 6
    go

    update sysloginroles set suid = 17 where suid = 7
    go

    sp_configure 'allow updates to system tables', 0
    go
    ----------------------------------------------------------------


    ----------------------------------------------------------------
    5) Confirmed the SUIDs in syslogins
    ----------------------------------------------------------------
    select suid, dbname, name, fullname from syslogins
    go

    suid dbname name fullname
    ------- ----------- ---------- ---------------
    1 master sa (null)
    2 sybsystemdb probe (null)
    16 master sa_dbateam User Name01
    17 master sa_appteam User Name02
    18 master dbo_appteam User Name 03
    ----------------------------------------------------------------


    ----------------------------------------------------------------
    6) Confirmed the SUIDs in sysloginroles
    ----------------------------------------------------------------
    select * from sysloginroles
    go

    suid srid status
    ------- ------- ---------
    1 0 1
    1 1 1
    1 2 1
    1 3 1
    16 0 1
    16 1 1
    16 2 1
    16 3 1
    17 0 1
    17 1 1
    17 2 1
    17 3 1
    ----------------------------------------------------------------

  4. #4
    Join Date
    Mar 2007
    Posts
    167

    PART 2 - Do I need to reinstall ASE now?

    This server is a fresh install and only has system databases at this time. I'm concerned about the two system databases you mentioned...

    - syssrvroles
    - sysattributes.object_type='UR'

    I did the following...


    ----------------------------------------------------------------
    1) Searched sysattributes for 'UR' object_type.
    ----------------------------------------------------------------
    select * from sysattributes where object_type = 'UR'
    go

    class attribute object_type object_cinfo object object_info1 object_info2 object_info3 int_value char_value text_value image_value comments
    -------- ------------ -------------- --------------- --------- --------------- --------------- --------------- ------------ ------------- ------------- -------------- -----------

    0 record(s) selected [Fetch MetaData: 0/ms] [Fetch Data: 0/ms]

    NOTE: Nothing was returned.
    ----------------------------------------------------------------


    ----------------------------------------------------------------
    2) Searched sysattributes for 'PS' object_type.
    ----------------------------------------------------------------
    select * from sysattributes where object_type = 'PS' order by object_cinfo
    go

    class attribute object_type object_cinfo object object_info1 object_info2 object_info3 int_value char_value text_value image_value comments
    -------- ------------ -------------- --------------- --------- --------------- --------------- --------------- ------------ ------------- ------------- -------------- -----------
    14 1 PS login 5 (null) (null) (null) 6 (null) (null) (null) (null)
    14 1 PS login 6 (null) (null) (null) 6 (null) (null) (null) (null)
    14 1 PS login 7 (null) (null) (null) 6 (null) (null) (null) (null)
    14 1 PS login 8 (null) (null) (null) 6 (null) (null) (null) (null)
    14 2 PS login 5 (null) (null) (null) 10 (null) (null) (null) (null)
    14 2 PS login 6 (null) (null) (null) 10 (null) (null) (null) (null)
    14 2 PS login 8 (null) (null) (null) 10 (null) (null) (null) (null)
    14 3 PS ps_attr (null) (null) (null) (null) (null) (null) (null) (null) (null)
    14 0 PS role 0 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 1 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 2 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 3 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 4 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 5 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 7 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 8 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 10 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 11 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 12 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 13 (null) (null) (null) 0 (null) (null) (null) (null)
    14 0 PS role 14 (null) (null) (null) 0 (null) (null) (null) (null)

    21 record(s) selected [Fetch MetaData: 0/ms] [Fetch Data: 21/ms]

    NOTE: I'm concerned with the results returned by object_cinfo.
    ----------------------------------------------------------------


    ----------------------------------------------------------------
    3) Confirmed syssrvroles.
    ----------------------------------------------------------------
    select * from syssrvroles
    go

    srid name password pwdate status logincount
    ------- ---------------- ----------- --------- --------- -------------
    0 sa_role (null) (null) (null) (null)
    1 sso_role (null) (null) (null) (null)
    2 oper_role (null) (null) (null) (null)
    3 sybase_ts_role (null) (null) (null) (null)
    4 navigator_role (null) (null) (null) (null)
    5 replication_role (null) (null) (null) (null)
    7 dtm_tm_role (null) (null) (null) (null)
    8 ha_role (null) (null) (null) (null)
    10 mon_role (null) (null) (null) (null)
    11 js_admin_role (null) (null) (null) (null)
    12 messaging_role (null) (null) (null) (null)
    13 js_client_role (null) (null) (null) (null)
    14 js_user_role (null) (null) (null) (null)
    ----------------------------------------------------------------

  5. #5
    Join Date
    Mar 2007
    Posts
    167

    I went ahead and re-installed ASE from¥ scratch... :)

    Since I had the luxary to re-install, before user objects are on the server, I went ahead and did so.

    Good lessons to learn and really appreciate you insight and advice. I've learned a lot in this experience.

    Before creating new logins, I will migrate the users from Production. Then I will create local logins accordingly.

    To my understanding, when I migrate users from the Production server to the Development server, I need to do the following...

    Sync. the following system databases...

    - syssrvroles (which currently seems to be the same across all servers)
    - syslogins
    - sysloginroles
    - sysattributes (which currently seems to be the same accross all servers with both the object_type of 'UR' and 'PS'). No attributes set at this time.

    Is this correct? What are your thoughts?

    Lessons learned... do not edit the sysattributes manually. Is this correct?

    A million thanks for all your help. Many many thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •