在make之前,将MAKEFILE中的do abi check注释,不要注释名字。。。

mysql 5.1 编译安装

分类: mysql2012-04-06 13:01 17175人阅读 评论(0) 收藏 举报

---------1.install mysql

--1.为mysql新建组和用户

#groupadd mysql

#useradd -g mysql  mysql

--2.检查是否有编译器

#su - root

#rpm -qa | grep gcc gcc-c++

--3.解压
#cd /usr/local/src

# tar xvzf mysql-5.1.47.tar.gz

# cd mysql-5.1.47

--4.配置和编译

#chmod +x configure

# ./configure --prefix=/usr/local/mysql --enable-local-infile

#make

#make install

--5.安装选项文件,将当前文件作为模板

#cp support-files/my-medium.cnf /etc/my.cnf

--6.设置mysql权限

#cd /usr/local/mysql

#chown -R mysql .

#chgrp -R mysql .

--7.新建mysql允许的表

#/usr/local/mysql/bin/mysql_install_db --user=mysql

#chown -R mysql var

--8.设置mysql开机自启动:

# cp /usr/local/src/mysql-5.1.47/support-files/mysql.server /etc/rc.d/init.d/mysql

#chmod +x /etc/rc.d/init.d/mysql

#chkconfig --add mysql

--9.测试并运行mysql

#/usr/local/mysql/bin/mysqld_safe --user=mysql &

#service mysql start

--10.修改mysql管理员密码
#/usr/local/mysql/bin/mysqladmin -u root password password

--11.使用用户登录mysql
# /usr/local/mysql/bin/mysql -u root -p

--12.链接mysql代码

# cd /usr/local/mysql/bin/
#for file in *;
> do 
> ln -s /usr/local/mysql/bin/$file /usr/bin/$file;
> done

测试mysql在任意地点能启动mysql:

#cd

# mysql -u root -p

Enter password: 
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 7
Server version: 5.1.47-log Source distribution

Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL v2 license

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql>

--13.查看端口3306

#netstat -atln

mysql 5.1.34的更多相关文章

  1. Install Apache 2.2.15, MySQL 5.5.34 & PHP 5.5.4 on RHEL/CentOS 6.4/5.9 & Fedora 19-12 [转]

    Step 1: Installing Remi Repository ## Install Remi Repository on Fedora , , , , ## rpm -Uvh http://d ...

  2. debian下安装mysql 5.1.34

    #cd /usr/local/src # tar xvzf mysql-5.1.34.tar.gz # cd mysql-5.5.1.34 配置和编译 #chmod +x configure # ./ ...

  3. mysql 5.6.34 二进制

    安装方法 http://dev.mysql.com/doc/refman/5.6/en/binary-installation.html shell> groupadd mysqlshell&g ...

  4. mysql-5.6.34 Installation from Source code

    Took me a while to suffer from the first successful souce code installation of mysql-5.6.34. Just pu ...

  5. mysql 主主互备

    双机热备的概念简单说一下,就是要保持两个数据库的状态自动同步.对任何一个数据库的操作都自动应用到另外一个数据库,始终保持两个数据库数据一致. 这样做的好处多. 1. 可以做灾备,其中一个坏了可以切换到 ...

  6. mysql 数值函数

    可使用常见的算术操作符.注意就 -. +和 *而言, 若两个参数均为正数,则其计算结果的精确度为 BIGINT (64比特),若其中一个参数为无符号整数, 而其它参数也是整数, 则结果为无符号整数.请 ...

  7. SqlServer与MySql的一些常用用法的差别

    最近学习了一下mySql,总结一下SqlServer不同一些用法: 操作符优先级以下列表显示了操作符优先级的由低到高的顺序.排列在同一行的操作符具有相同的优先级.:=||, OR, XOR&& ...

  8. mysql 函数编程大全(持续更新)

    insert ignore insert ignore表示,如果中已经存在相同的记录,则忽略当前新数据 如果您使用一个例如“SET col_name = col_name + 1”的赋值,则对位于右侧 ...

  9. Mysql --分区表(5)Columns分区

    COLUMNS分区 COLUMNS分区是RANGE和LIST分区的变种.COLUMNS分区支持多列作为分区键进行分区 RANGE COLUNMS分区和LIST COLUMNS都支持非INT型列作为分区 ...

随机推荐

  1. JavaScript之基础语法

    第一章 javascript语法 一, js代码的引入 方式一:在html页写js代码 <script> alert('hello,world') </script> 方式二: ...

  2. 3486 ( Interviewe )RMQ

    Problem Description YaoYao has a company and he wants to employ m people recently. Since his company ...

  3. P4514 上帝造题的七分钟(二维树状数组)

    P4514 上帝造题的七分钟 二维树状数组 差分维护区间加法,区间求和 #include<cstdio> int read(){ ,f=; ') f=f&&(c!='-') ...

  4. C# 中File和FileStream的用法

    原文:https://blog.csdn.net/qq_41209575/article/details/89178020 1.首先先介绍File类和FileStream文件流 1.1  File类, ...

  5. javascript实现快速排序算法

    忘记了快速排序的思路是怎样的了,复习一下,写了两个实例,发表博文备忘. 对于快速排序的思想,可以参考白话经典算法系列之六 快速排序 快速搞定,讲得比较通俗 prototype扩展的方式 /** * 对 ...

  6. vue.js(18)--父组件向子组件传值

    子组件是不能直接使用父组件中数据的,需要进行属性绑定(v-bind:自定义属性名=“msg”),绑定后需要在子组件中使用props[‘自定义属性名’]数组来定义父组件的自定义名称. props数组中的 ...

  7. Ansible自动化运维工具(1)

    1. Ansible的架构 Ansible的帮助文档: http://www.ansible.com.cn/index.html 2. YAML语言简介 基本规则 列表(list, [, , , .. ...

  8. maven 常用插件 拷贝依赖 拷贝jar包 查看属性 环境变量

    1 maven编译后希望将生产的jar包拷贝到指定目录 在pom中配置maven插件 maven-antrun-plugin <build > <plugins> <pl ...

  9. AOP技术介绍--(.Net中关于AOP的实现)

    一.AOP实现初步       AOP将软件系统分为两个部分:核心关注点和横切关注点.核心关注点更多的是业务逻辑,关注的是系统核心的业务:而横切关注点虽与核心的业务实现无关,但它却是一种更通用的业务, ...

  10. 美国知名Cloudflare网络公司遭中国顶尖黑客攻击

    最近中美贸易战愈演愈烈,美国知名Cloudflare网络公司的客户的分布式拒绝服务攻击今天在恶意流量方面达到了新的高度,黑客并袭击了该公司在欧洲和美国的数据中心.根据Cloudflare首席执行官马修 ...