大橙子网站建设,新征程启航
为企业提供网站建设、域名注册、服务器等服务
aix下让sybase的所有库从一个存储迁移到另一个存储,或者从一个vg迁移到另一个vg,抑或移动sybase所有库到新的位置,在aix下都可以通过拷贝相关lv实现。由于公司ibm小型机硬件原因,简单举个迁移sybase设备从rootvg上到datavg的例子。过程如下:
公司主营业务:成都网站制作、成都做网站、移动网站开发等业务。帮助企业客户真正实现互联网宣传,提高企业的竞争能力。创新互联是一支青春激扬、勤奋敬业、活力青春激扬、勤奋敬业、活力澎湃、和谐高效的团队。公司秉承以“开放、自由、严谨、自律”为核心的企业文化,感谢他们对我们的高要求,感谢他们从不同领域给我们带来的挑战,让我们激情的团队有机会用头脑与智慧不断的给客户带来惊喜。创新互联推出头屯河免费做网站回馈大家。一、基本信息
1 数据库当前的设备如下
name phyname
------------------------------ ------------------------
master /dev/rlv_master
sysprocsdev /dev/rlv_proc
2 rootvg的lv信息
# lsvg -l rootvg
rootvg:
LV NAME TYPE LPs PPs PVs LV STATE MOUNT POINT
hd5 boot 1 1 1 closed/syncd N/A
hd6 paging 64 64 1 open/syncd N/A
hd8 jfs2log 1 1 1 open/syncd N/A
hd4 jfs2 48 48 1 open/syncd /
hd2 jfs2 64 64 1 open/syncd /usr
hd9var jfs2 48 48 1 open/syncd /var
hd3 jfs2 48 48 1 open/syncd /tmp
hd1 jfs2 1 1 1 open/syncd /home
hd10opt jfs2 48 48 1 open/syncd /opt
lg_dumplv sysdump 16 16 1 open/syncd N/A
lv_master raw 5 5 1 open/syncd N/A
lv_proc raw 5 5 1 open/syncd N/A
lv_data1 raw 16 16 1 closed/syncd N/A
3 sybase RUN_CRM 文件内容如下
$ cat RUN_CRM
#!/bin/sh
#
# Adaptive Server name: CRM
# ASE page size (KB): 2k
# Master device path: /dev/rlv_master
# Error log path: /sybase/ASE-12_5/install/CRM.log
# Configuration file path: /sybase/ASE-12_5/CRM.cfg
# Directory for shared memory files: /sybase/ASE-12_5
#
/sybase/ASE-12_5/bin/dataserver \
-sCRM \
-d/dev/rlv_master \
-e/sybase/ASE-12_5/install/CRM.log \
-c/sybase/ASE-12_5/CRM.cfg \
-M/sybase/ASE-12_5 \
4 sybase的接口文件内容如下:
# cat interfaces
CRM
master tcp ether 192.168.85.9 5000
query tcp ether 192.168.85.9 5000
CRM_back
master tcp ether 192.168.85.9 5001
query tcp ether 192.168.85.9 5001
二、拷贝sybase的所有相关lv、本例sybase只有lv_master lv_proc两个lv (注意由于是简单模拟实验,所以sybase就只有这么两个lv)
1 拷贝过程如下:
cplv命令解释如下:
-y 新的lv名字
-v 目标卷组名字
# cplv -y newlv_master -v datavg lv_master
cplv: Logical volume lv_master successfully copied to newlv_master .
# cplv -y newlv_proc -v datavg lv_proc
cplv: Logical volume lv_proc successfully copied to newlv_proc .
2 拷贝lv后datavg 的lv信息如下:
# lsvg -l datavg
datavg:
LV NAME TYPE LPs PPs PVs LV STATE MOUNT POINT
lv_backup jfs2 320 320 1 open/syncd /backup
loglv00 jfs2log 1 1 1 open/syncd N/A
newlv_master raw 10 10 1 closed/syncd N/A
newlv_proc raw 10 10 1 closed/syncd N/A
三、更改lv名字
1 更改原rootvg上sybaselv的名字
chlv命令参数解释如下:
-n 为新lv名字
# chlv -n oldlv_master lv_master
# chlv -n oldlv_proc lv_proc
2 更改datavg上lv名字(由newlv_master--> lv_master| newlv_proc-->lv_proc)
# chlv -n lv_master newlv_master
# chlv -n lv_proc newlv_proc
四、启动服务后测试情况如下
1 启动主服务和备份服务
$ startserver -f RUN_CRM
$ startserver -f RUN_CRM_back
2 验证
如下可看到sybase主备服务已经启动成功
$ showserver
USER PID %CPU %MEM SZ RSS TTY STAT STIME TIME COMMAND
sybase 319558 2.0 2.0 25564 17188 pts/1 A 11:42:25 0:03 /sybase/ASE-12_5/bin/dataserver -sCRM -d/dev/rlv_master -e/sybase/ASE-12_5/install/CRM.log -c/sybase/ASE-12_5/CRM.cfg -M/sybase/ASE-12_5
sybase 286878 0.0 1.0 7016 7440 pts/1 A 11:43:14 0:00 /sybase/ASE-12_5/bin/backupserver -SCRM_back -e/sybase/ASE-12_5/install/CRM_back.log -Ldefault -Jcp850 -N25 -C20 -M/sybase/ASE-12_5/bin/sybmultbuf
验证下master库能否备份,如下:
$ isql -Usa -P -SCRM
1> dump database master to '/backup/master2.dat'
2> go
WARNING: In order to LOAD the master database, the SQL Server must run in
single-user mode. If the master database dump uses multiple volumes, you must
execute sp_volchanged on another SQL Server at LOAD time in order to signal
volume changes.
Backup Server session id is: 5. Use this value when executing the
'sp_volchanged' system stored procedure after fulfilling any volume change
request from the Backup Server.
Backup Server: 4.41.1.1: Creating new disk file /backup/master2.dat.
Backup Server: 6.28.1.1: Dumpfile name 'master132960A524 ' section number 1
mounted on disk file '/backup/master2.dat'
Backup Server: 4.58.1.1: Database master: 4546 kilobytes DUMPED.
Backup Server: 4.58.1.1: Database master: 4716 kilobytes DUMPED.
Backup Server: 4.58.1.1: Database master: 4888 kilobytes DUMPED.
Backup Server: 4.58.1.1: Database master: 5058 kilobytes DUMPED.
Backup Server: 4.58.1.1: Database master: 5230 kilobytes DUMPED.
Backup Server: 4.58.1.1: Database master: 5400 kilobytes DUMPED.
Backup Server: 4.58.1.1: Database master: 5572 kilobytes DUMPED.
Backup Server: 4.58.1.1: Database master: 5710 kilobytes DUMPED.
Backup Server: 3.43.1.1: Dump phase number 1 completed.
Backup Server: 3.43.1.1: Dump phase number 2 completed.
Backup Server: 3.43.1.1: Dump phase number 3 completed.
Backup Server: 4.58.1.1: Database master: 5718 kilobytes DUMPED.
Backup Server: 3.42.1.1: DUMP is complete (database master).
另外有需要云服务器可以了解下创新互联cdcxhl.cn,海内外云服务器15元起步,三天无理由+7*72小时售后在线,公司持有idc许可证,提供“云服务器、裸金属服务器、高防服务器、香港服务器、美国服务器、虚拟主机、免备案服务器”等云主机租用服务以及企业上云的综合解决方案,具有“安全稳定、简单易用、服务可用性高、性价比高”等特点与优势,专为企业上云打造定制,能够满足用户丰富、多元化的应用场景需求。