master

mysql+centos7+主从复制

社会主义新天地 提交于 2019-12-03 10:16:44
MYSQL(mariadb) MariaDB数据库管理系统是MySQL的一个分支,主要由开源社区在维护,采用GPL授权许可。开发这个分支的原因之一是:甲骨文公司收购了MySQL后,有将MySQL闭源的潜在风险,因此社区采用分支的方式来避开这个风险。MariaDB的目的是完全兼容MySQL,包括API和命令行,使之能轻松成为MySQL的代替品。 方法1:yum安装mariadb Red Hat Enterprise Linux/CentOS 7.0 发行版已将默认的数据库从 MySQL 切换到 MariaDB。 第一步:添加 MariaDB yum 仓库 1、首先在 RHEL/CentOS 和 Fedora 操作系统中添加 MariaDB 的 YUM 配置文件 MariaDB.repo 文件。 #编辑创建mariadb.repo仓库文件 vi /etc/yum.repos.d/MariaDB.repo 2、添加repo仓库配置 [mariadb] name = MariaDB baseurl = http://yum.mariadb.org/10.1/centos7-amd64 gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB gpgcheck=1 第二步:在 CentOS 7 中安装 MariaDB 2、当 MariaDB

Programmatically show / hide master view in UISplitViewController

匿名 (未验证) 提交于 2019-12-03 10:10:24
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 由 翻译 强力驱动 问题: I have an app that uses a UISplitViewController. When in Landscape orientation, we sometimes want to show the master view all the time and sometimes want it to auto hide as it does in portrait orientation. Currently this setting can be tweaked in app. This all works well, except for one thing. When I change the setting, I'd like the auto-hide setting to take effect immediately, not just the next time I rotate the device (i.e. when - splitViewController:shouldHideViewController:inOrientation: is called). Is there some way to

Git: temporarily reverting pushed commit(s)

匿名 (未验证) 提交于 2019-12-03 10:10:24
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 由 翻译 强力驱动 问题: Say, you've pushed some commits and pulled them into production, in your server's webroot, for example. And then something goes wrong. Clearly, most often what you want to do is temporarily revert the files in the webroot to some previous state, then go back to your local development place, fix what is broken, test it, commit on top of commits that broke something and push these new fixing commits to the master branch. And then just go to the production webroot again and pull everything to the latest commit so everything is fixed

Git - how to rollback

匿名 (未验证) 提交于 2019-12-03 10:09:14
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I know this question has been asked before but although the given answer git reset --hard HEAD~1 works, I cannot push it to the server since the server is ahead. Pulling obviously puts me right back where I was. How do I reset the server? 回答1: you want to force a push, only use this if you are certain of the change. git push origin --force 回答2: Force pushing is an option, if your colleagues accepts to reset their own local branch to the new origin/master (assuming we are talking about that 'master' branch). git fetch git reset origin/master

Correct @EnableRedisHttpSession configuration with Redis Sentinel

匿名 (未验证) 提交于 2019-12-03 09:52:54
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I have a Spring Cloud based application with multiple backend Spring-Boot servers. The servers are all sharing their session with a Redis server via @EnableRedisHttpSession. I'm trying to configure the application with master-slave configuration and Redis Sentinel. My setup is 1 master, two slaves, and 3 sentinels. I keep getting issues with the environment. At first, I was getting an error saying that my slave it READONLY. So I had to set all slaves to READWRITE. Then, I still got this error. Turns out that when a slave was promoted to

GIT

元气小坏坏 提交于 2019-12-03 09:48:43
GIT版本管理工具教程 一 Git初始化 下载安装, 下载地址: https://git-scm.com/downloads 每个系统的都有(linux、mac、windows等),看官网的安装教程,很详细,此处我以windows来练习 首先创建一个文件夹,这个文件夹就是我们将来通过git来管理的所有文件的存放地点 。 在文件夹中右键 使用Git Bash 在弹出的窗口中执行初始化指令,让git帮我们对这个文件夹中的所有文件以及文件夹进行管理 git init #创建git版本管理的本地仓库 产生的.git文件夹用来存放你管理的文件的所有版本以及git配置相关的内容,不要轻易动它 二 简单指令使用 基本操作 git status 查看仓库中所有的文件夹和文件的状态 git add supercrm 让git管理单独的文件夹或者文件 git add . 管理所有文件和文件夹 配置用户名和邮箱 $ git config --global user.name <用户名> $ git config --global user.email <邮箱地址> 例如: $ git config --global user.name "吴超" $ git config --global user.email "1069696250@qq.com" 然后就可以提交版本了,看指令 git commit

Git: move changes off of master branch

若如初见. 提交于 2019-12-03 09:27:38
Basic question but this happens to me all the time: Make changes in a working-branch Switch to master git merge working-branch git push cap deploy (to staging) make a new cup of tea then I come back and think of something else and start making some changes...while still on master. What's an easy way to either: prevent direct edits on master (warning perhaps) to move all edits over to working-branch and clear master so I can continue editing on working-branch to spin edits into an entirely new branch new-working-branch and then discard working-branch ? Took a risk and tried recommendation in

MySQL学习笔记(基础部分)-单实例mysql-5.5.X安装

a 夏天 提交于 2019-12-03 09:23:22
MySQL学习笔记(平台CentOS 6) 1、建立mysql账号 [root@mysql-master tools]# groupadd mysql [root@mysql-master tools]# useradd -s /sbin/nologin -g mysql -M mysql 2、配置安装环境 [root@mysql-master ~]# yum groupinstall 'Development Tools' -y [root@mysql-master ~]# yum install gcc gcc-c++ make ncurses-devel bison perl -y # 依赖包 安装cmake [root@mysql-master tools]# tar -zxf cmake-2.8.12.tar.gz # 安装cmake [root@mysql-master tools]# cd cmake-2.8.12 [root@mysql-master cmake-2.8.12]# ./configure [root@mysql-master cmake-2.8.12]# gmake [root@mysql-master cmake-2.8.12]# gmake install [root@mysql-master cmake-2.8.12]# which cmake

Git - pushing to remote repository

匿名 (未验证) 提交于 2019-12-03 09:14:57
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: Git newbie here. created a new folder: mkdir hello_master cd hello_master touch test.txt git init git add test.txt git commit test.txt then cloned the repository git clone hello_master hello_local # made some changes to test.txt and committed it how do I push it to hello_master ? if I do a git push, it is complaining saying I can't push to hello_master . But if I go to hello_master , I can pull and get all changes from hello_local . What am I doing wrong? 回答1: Nothing. You just can't push to a non-bare repository. Because git wouldn't know

git checkout &lt; branch &gt; failure for local changes

匿名 (未验证) 提交于 2019-12-03 09:14:57
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I am new to Git. It seems to be a fantastic non-liner workflow based on the Directed Acyclic Graph. According to the git checkout doc : git checkout <branch> To prepare for working on , switch to it by updating the index and the files in the working tree, and by pointing HEAD at the branch. Local modifications to the files in the working tree are kept, so that they can be committed to the <branch> . I have 2 branches: master dev Both branches are clean and up-to-date. I did this: git checkout dev <change a tracked file> git checkout master