You are not logged in or registered. Please login or register to use the full functionality of this Website SybaseTeam.Com...
Hello There, Guest! (LoginRegister) Remember Me? Current time: 10-20-2014, 06:11 PM
   Home  |  About Us  |  Sybase Training  |  Synergy  |  Consulting  |  Job Openings  |  Tech Videos  |  Rules and Disclaimer  |  Search
Post Reply 
Forum Tools
Sybase ASE server naming and renaming
04-27-2009, 02:55 AM
Post: #1
Quote this message in a reply
Sybase ASE server naming and renaming


There are three totally separate places where ASE names reside, causing much confusion.
ASE Host Machine interfaces File

A master entry in here for server TEST will provide the network information that the server is expected to listen on. The -S parameter to the dataserver executable tells the server which entry to look for, so in the RUN_TEST file, -STEST will tell the dataserver to look for the entry under TEST in the interfaces file and listen on any network parameters specified by 'master' entries.

TEST
master tcp ether hpsrv1 1200
query tcp ether hpsrv1 1200

Note that preceding the master/query entries there's a tab.

This is as far as the name TEST is used. Without further configuration the server does not know its name is TEST, nor do any client applications. Typically there will also be query entries under TEST in the local interfaces file, and client programs running on the same machine as the server will pick this connection information up. However, there is nothing to stop the query entry being duplicated under another name entirely in the same interfaces file.

ARTHUR
query tcp ether hpsrv1 1200

isql -STEST or isql -SARTHUR will connect to the same server. The name is simply a search parameter into the interfaces file.
Client Machine interfaces File

Again, as the server name specified to the client is simply a search parameter for Open Client into the interfaces file, SQL.INI or WIN.INI the name is largely irrelevant. It is often set to something that means something to the users, especially where they might have a choice of servers to connect to. Also multiple query entries can be set to point to the same server, possibly using different network protocols. eg. if TEST has the following master entries on the host machine:

TEST
master tli spx /dev/nspx/ \xC12082580000000000012110
master tcp ether hpsrv1 1200

Then the client can have a meaningful name:

ACCOUNTS_TEST_SERVER
query tcp ether hpsrv1 1200

or alternative protocols:

TEST_IP
query tcp ether hpsrv1 1200
TEST_SPX
query tli spx /dev/nspx/ \xC12082580000000000012110

sysservers

This system table holds information about remote ASEs that you might want to connect to, and also provides a method of naming the local server.

Entries are added using the sp_addserver system procedure - add a remote server with this format:

sp_addserver server_name, null, network_name

server_name is any name you wish to refer to a remote server by, but network_name must be the name of the remote server as referenced in the interfaces file local to your local server. It normally makes sense to make the server_name the same as the network_name, but you can easily do:

sp_addserver LIVE, null, ACCTS_LIVE

When you execute for example, exec LIVE.master..sp_helpdb the local ASE will translate LIVE to ACCTS_LIVE and try and talk to ACCTS_LIVE via the ACCTS_LIVE entry in the local interfaces file.

Finally, a variation on the sp_addserver command:

sp_addserver LOCALSRVNAME, local

names the local server (after a restart). This is the name the server reports in the errorlog at startup, the value returned by @@SERVERNAME, and the value placed in Open Client server messages. It can be completely different from the names in RUN_SRVNAME or in local or remote interfaces - it has no bearing on connectivity matters.


Find all posts by this user
05-29-2009, 05:47 PM
Post: #2
Quote this message in a reply
RE: Rename Sybase Server


OR YOU CAN USE THE STEPS BELOW MENTIONED.

(1) In master..sysservers table Drop server and add server with desired name using sp_dropserver and sp_addserver
(2) Shut down the sybase server(on unix,using isql session use command shutdown or shutdown witrh no wait.
(3) Edit interface files $SYBASE/interfaces and update query and master records.
(4)Update new sybase servername in RUN_SYBASESERVER file for -S parater , rename RUN_SERVER file (directory : $SYBASE/$SYBASE_ASE/install)
(5)Rename .cfg and errorlog file for server name in RUN_SERVER file
(6) Rename existing .cfg file in $SYBASE dir
(7)Modify DSQUERY and DSLISTEN for correct servername
(8)start the sybase server $ startserver -f RUN_SYBASESERVER


Find all posts by this user
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  How to add a user to all databases on a server tango29 3 2,052 08-10-2014 04:06 PM
Last Post: Bahubali
  Renaming ASE server Surya_VR 2 2,059 03-21-2013 02:49 PM
Last Post: mvsramarao
  Starting a Database server vinayp83 1 1,884 10-01-2012 08:05 AM
Last Post: DerekAsirvadem
  TO CLUSTER OR NOT TO CLUSTER: WHY SYBASE ASE CE/HA AND SYBASE REPLICATION SERVER WARM Andrew Melkonyan 0 1,406 08-06-2012 03:46 AM
Last Post: Andrew Melkonyan
  01:00000:00056:2012/04/22 19:15:49.65 server SQL Server shutdown by request. mejjagiri 3 1,830 06-14-2012 04:29 AM
Last Post: mejjagiri
  knowing actual server from admin show_connections Kai 1 1,878 04-09-2012 01:17 PM
Last Post: ashwin510
  Refreshing of two different databases on a single server. raograjiv 1 1,758 04-09-2012 01:13 PM
Last Post: ashwin510
  Backup Server Down Nad_123 3 1,789 11-28-2011 04:54 AM
Last Post: DerekAsirvadem
  What traceflags, if any, are currently active in the sybase ase server Kishor 1 2,933 01-20-2011 12:38 PM
Last Post: Paprsek
  Unable to start the Backup Server - Failed to start any network listeners on solaris Joshi 3 11,097 04-22-2010 05:21 PM
Last Post: sybanva

Options:
Forum Jump:


Contact Us | SybaseTeam | Disclaimer & Rules | Return to Top | Return to Content | Lite (Archive) Mode | RSS Syndication