Manual database creation for DB2 in the SUSELinux Environment

Source: Internet
Author: User
1, create a space mkdir-pdb2roottestdblv_db2dbmkdir-pdb2roottestdblv_db2indexmkdir-pdb2roottestdblv for the db data file _

1. Create a space for the db data file mkdir-p/db2root/testdb/lv_db2dbmkdir-p/db2root/testdb/lv_db2indexmkdir-p/db2root/testdb/lv _

Homepage → Database Technology

Background:

Read News

Manual database creation for DB2 in SUSE Linux

[Date:] Source: Linux community Author: Linux editor [Font:]

1. Create a space for the db Data File

Mkdir-p/db2root/testdb/lv_db2db
Mkdir-p/db2root/testdb/lv_db2index
Mkdir-p/db2root/testdb/lv_db2log
Mkdir-p/db2root/testdb/lv_1_bs
Mkdir-p/db2root/testdb/lv_temptbs
Touch/db2root/testdb/lv_usertbs
Chown-R db2inst1: db2grp1/db2root/testdb

2. Create a database under an instance user (in db2 Mode)

Create database testdb on/db2root/testdb/lv_db2db using codeset GBK territory zh_CN collate using identity catalog tablespace managed by system using ('/db2root/testdb/lv_systbs/catalog ') TEMPORARY tablespace managed by system using ('/db2root/testdb/lv_temptbs/temporary') user tablespace managed by database using (file '/db2root/testdb/lv_usertbs' 2621440)

3. Set db Parameters

Connect to testdb
Update db cfg for mmscdb using newlogpath/db2root/testdb/lv_db2log logprimary 20 logfilsiz 7680
Update db cfg using implements theap 16384
Update db cfg using implements theap 16384
Update db cfg using APPLHEAPSZ 512

4. authorize user user1

Connect to testdb user db2inst1 using passwd
Grant use of tablespace USERSPACE1 to user user1
Grant dbadm on database to user user1

  • 0
  • How to compile and install MySQL from the source code on Linux

    Connect c ++ in Ubuntu to the database

    Related information suse

    Image Information

    View All comments in this article (0)

    Comments

    Latest Information

    Popular this week

    Introduction to Linux community-advertisement service-website map-help Info-contact us
    The articles published on this site (LinuxIDC) do not mean that they agree with the statement or description. They only provide more information and do not constitute any suggestions.


    Copyright©2006-2011 Linux community All rights reserved Zhejiang ICP backup No. 06018118

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.