mdadm
zhongchanghui / md Goto Github PK
View Code? Open in Web Editor NEWmdadm
mdadm
Hi,
I found resize function for vfat FS does not work on rhel7. The size of disk is 20G. The size of VG is 20G. volume size has not changed when do resize from 19g to 25g, but the output by the terminal shows passed and does not report ERROR "exceed the size of disk".
---
- hosts: all
become: true
vars:
mount_location: '/opt/test1'
volume_group_size: '20g'
volume_size_before: '19g'
volume_size_after: '25g'
storage_safe_mode: false
tasks:
- include_role:
name: storage
- include_tasks: get_unused_disk.yml
vars:
min_size: "{{ volume_group_size }}"
max_return: 1
- name: Create one LVM logical volume with "{{ volume_size_before }}" under one volume group
include_role:
name: storage
vars:
storage_pools:
- name: foo
disks: "{{ unused_disks }}"
type: lvm
volumes:
- name: test1
fs_type: 'vfat'
size: "{{ volume_size_before }}"
mount_point: "{{ mount_location }}"
- shell: lsblk | grep foo-test1
- shell: mount | grep foo-test1
- include_tasks: verify-role-results.yml
- name: Change volume_size "{{ volume_size_after }}"
include_role:
name: storage
vars:
storage_pools:
- name: foo
type: lvm
disks: "{{ unused_disks }}"
volumes:
- name: test1
fs_type: 'vfat'
size: "{{ volume_size_after }}"
mount_point: "{{ mount_location }}"
- shell: lsblk | grep foo-test1
- shell: mount | grep foo-test1
- include_tasks: verify-role-results.yml
- name: Clean up
include_role:
name: storage
vars:
storage_pools:
- name: foo
disks: "{{ unused_disks }}"
state: absent
volumes:
- name: test1
size: "{{ volume_size_after }}"
mount_point: "{{ mount_location }}"
- include_tasks: verify-role-results.yml
task path: /root/ansible-test/upstream/storage/tasks/main-blivet.yml:113
ok: [192.168.122.96] => {
"blivet_output": {
"actions": [],
"changed": false,
"failed": false,
"leaves": [
"/dev/vda1",
"/dev/mapper/rhel_ansible--el7-swap",
"/dev/mapper/rhel_ansible--el7-root",
"/dev/mapper/foo-test1",
"/dev/vdc",
"/dev/sr0"
],
"mounts": [
{
"dump": 0,
"fstype": "vfat",
"opts": "defaults",
"passno": 0,
"path": "/opt/test1",
"src": "/dev/mapper/foo-test1",
"state": "mounted"
}
],
"packages": [
"dosfstools",
"xfsprogs",
"e2fsprogs",
"lvm2"
],
"pools": ['''
{
"disks": [
"vdb"
],
"name": "foo",
"state": "present",
"type": "lvm",
"volumes": [
{
"_device": "/dev/mapper/foo-test1",
"_mount_id": "/dev/mapper/foo-test1",
"fs_create_options": "",
"fs_label": "",
"fs_overwrite_existing": true,
"fs_type": "vfat",
"mount_check": 0,
"mount_device_identifier": "uuid",
"mount_options": "defaults",
"mount_passno": 0,
"mount_point": "/opt/test1",
"name": "test1",
"pool": "foo",
"size": "25g",
"state": "present",
"type": "lvm"
}
]
}
],
"volumes": []
}
}
PLAY RECAP **************************************************************************************
192.168.122.96 : ok=173 changed=8 unreachable=0 failed=0 skipped=29 rescued=0 ignored=0
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.