我要评分
获取效率
正确性
完整性
易理解

Deploying and Configuring Cobar

  1. Go to the /home/cobar-server-1.2.8-SNAPSHOT/bin directory.
    1
    cd /home/cobar-server-1.2.8-SNAPSHOT/bin
    
  2. Modify the startup.sh file.
    1. Open the file.
      1
      vim startup.sh
      
    2. Press i to enter the insert mode and replace line 38 with the following content:
      1
      JAVA_OPTS="-server -Xms10240m -Xmx10240m -Xmn8g -Xss328k"
      
    3. Press Esc, type :wq!, and press Enter to save the file and exit.
  3. Go to the /home/cobar-server-1.2.8-SNAPSHOT/conf directory.
    1
    cd /home/cobar-server-1.2.8-SNAPSHOT/conf
    
  4. Modify the schema.xml file.
    1. Open the schema.xml file.
      1
      vim schema.xml
      
    2. Press i to enter the insert mode. Replace the MySQL information marked in the figure below with the actual MySQL information in the environment. schema.xml contains the IP addresses, port numbers, user name, and password of the MySQL database.
       1
       2
       3
       4
       5
       6
       7
       8
       9
      10
      11
      <!-- Data source definition. A data source is the representation of a specific backend data connection.-->
      <dataSource name="dsTest" type="mysql">
        <property name="location">
          <location>192.168.200.56:3306/dbtest1</location>
          <location>192.168.200.56:3306/dbtest2</location>
          <location>192.168.200.56:3306/dbtest3</location>
        </property>
        <property name="user">root</property>
        <property name="password">123456</property>
        <property name="sqlMode">STRICT_TRANS_TABLES</property>
      </dataSource>
      

    3. Press Esc, type :wq!, and press Enter to save the file and exit.
  5. View the server.xml file.
    1
    2
    cd /home/cobar-server-1.2.8-SNAPSHOT/conf
    cat server.xml
    

    The database name provided by the system is dbtest and the password is test.