[Android Software Development] hachamacha:
This is during a session of my not-working msm8960dt Philz Touch where I've got /data mounted and first I'll show some tests I do in "adb shell":

Notes addendum: When I received back a "permissions denied" status after trying to do a "touch testfile" (or what it's link points to) while on /sdcard, I checked the permissions on a) the link that is /sdcard, and the actual fs it points to which is "/data/media/0". Permissions were "dwrxwrx---", and ownership was root/root. I then did a "whoami" which returned "root".

I couldn't dismount /data completely, likely because there are perhaps files in use, and it returned a busy error, and I wasn't in the folder. I could as you'll see, do a "mount -o remount,ro(or rw) /data without any problem, and when mounted as read-only, it returned the status of "read-only" filesystem - write failed. When I did the remount again, it reverted to "permissions denied". OK: Thanks for looking at this.

/data/media/0 # df -h
df -h
Filesystem Size Used Available Use% Mounted on
tmpfs 877.8M 128.0K 877.7M 0% /dev
tmpfs 877.8M 612.0K 877.2M 0% /tmp
tmpfs 877.8M 0 877.8M 0% /storage
tmpfs 877.8M 0 877.8M 0% /mnt/secure
tmpfs 877.8M 0 877.8M 0% /mnt/fuse
/dev/block/platform/msm_sdcc.1/by-name/cache
1001.5M 17.3M 984.2M 2% /cache
[B]/dev/block/platform/msm_sdcc.1/by-name/userdata
26.3G 11.7G 14.4G 45% /data[/B]
/dev/block/platform/msm_sdcc.1/by-name/system
1.5G 847.2M 664.7M 56% /system
/data/media/0 # mount
mount
rootfs on / type rootfs (rw,seclabel)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
tmpfs on /tmp type tmpfs (rw,seclabel,relatime)
tmpfs on /storage type tmpfs (rw,seclabel,relatime,mode=050,gid=1028)
tmpfs on /mnt/secure type tmpfs (rw,seclabel,relatime,mode=700)
tmpfs on /mnt/fuse type tmpfs (rw,seclabel,relatime,mode=775,gid=1000)
/dev/block/platform/msm_sdcc.1/by-name/cache on /cache type ext4 (rw,seclabel,nodev,noatime,nodiratime,data=ordered)
[B]/dev/block/platform/msm_sdcc.1/by-name/userdata on /data type f2fs (rw,seclabel,nosuid,noatime,nodiratime,background_gc=on,discard,u[/B]
ser_xattr,inline_xattr,acl,errors=recover,active_logs=6)
/dev/block/platform/msm_sdcc.1/by-name/system on /system type ext4 (rw,seclabel,nodev,noatime,nodiratime,data=ordered)
[COLOR="Red"]/data/media/0 # touch /sdcard/testfile
touch /sdcard/testfile
touch: /sdcard/testfile: Permission denied
/data/media/0 # mount -o remount,ro /data
mount -o remount,ro /data
/data/media/0 # mount| grep "\data"
mount| grep "\data"
/dev/block/platform/msm_sdcc.1/by-name/cache on /cache type ext4 (rw,seclabel,nodev,noatime,nodiratime,data=ordered)
/dev/block/platform/msm_sdcc.1/by-name/userdata on /data type f2fs (ro,seclabel,nosuid,noatime,nodiratime,background_gc=off,discard,
user_xattr,inline_xattr,acl,errors=recover,active_logs=6)
/dev/block/platform/msm_sdcc.1/by-name/system on /system type ext4 (rw,seclabel,nodev,noatime,nodiratime,data=ordered)
/data/media/0 # touch /sdcard/testfile
touch /sdcard/testfile
touch: /sdcard/testfile: Read-only file system
/data/media/0 # mount -o remount,rw /data
mount -o remount,rw /data
/data/media/0 # touch /sdcard/testfile
touch /sdcard/testfile
touch: /sdcard/testfile: Permission denied[/COLOR]
/data/media/0 #

Now I'm going to boot up and get that log file from /cache/recovery, during which I went via the UI and did a mount of /data a couple of times.

__bionic_open_tzdata: couldn't find any tzdata when looking for localtime!
__bionic_open_tzdata: couldn't find any tzdata when looking for GMT!
__bionic_open_tzdata: couldn't find any tzdata when looking for posixrules!
Starting recovery on (UTC) Fri May 9 00:34:05 2014

can't open /dev/tty0: No such file or directory
framebuffer: fd 3 (720 x 1280)
PhilZ Touch 6.40.7
Clockworkmod v6.0.4.8
I:Device target: Moto X (cm_moto_msm8960dt)
I:Touch GUI revision: 1.21
No /etc/extra.fstab
recovery filesystem table
=========================
0 /data f2fs /dev/block/platform/msm_sdcc.1/by-name/userdata -16384
1 /cache ext4 /dev/block/platform/msm_sdcc.1/by-name/cache 0
2 /system ext4 /dev/block/platform/msm_sdcc.1/by-name/system 0
3 /fsg ext4 /dev/block/platform/msm_sdcc.1/by-name/fsg 0
4 /firmware ext4 /dev/block/platform/msm_sdcc.1/by-name/modem 0
5 /persist ext4 /dev/block/platform/msm_sdcc.1/by-name/persist 0
6 /boot emmc /dev/block/platform/msm_sdcc.1/by-name/boot 0
7 /recovery emmc /dev/block/platform/msm_sdcc.1/by-name/recovery 0
8 /modem ext4 /dev/block/platform/msm_sdcc.1/by-name/modem 0
9 /storage/usbdisk auto /devices/platform/msm_hsusb_host 0
10 /tmp ramdisk ramdisk 0

W:Unable to get recovery.fstab info for /datadata during fstab generation!
W:Unable to get recovery.fstab info for /emmc during fstab generation!
W:Unable to get recovery.fstab info for /preload during fstab generation!
W:Unable to get recovery.fstab info for /sdcard during fstab generation!
W:Unable to get recovery.fstab info for /sd-ext during fstab generation!
W:Unable to get recovery.fstab info for /external_sd during fstab generation!
I:Completed outputting fstab.
I:using /data/media/0 for /sdcard
I:Connected to Vold..
I:110 0 usbdisk /storage/usbdisk 0
I:200 0 Volumes listed.
I:Processing arguments.
I:Checking arguments.
I:device_recovery_start()
I:auto_restore_settings set to default (false)
I:check_root_and_recovery set to default (true)
I:compression_value set to default (low)
I:twrp_backup_mode set to default (false)
I:enable_md5sum set to default (1)
I:show_nandroid_size_progress set to default (1)
I:use_nandroid_simple_logging set to default (1)
I:nand_prompt_on_low_space set to default (1)
I:signature_check_enabled set to default (0)
I:install_zip_verify_md5 set to default (0)
I:set_brightness set to default (160)
I:menu_height_increase=30
I:show_virtual_keys=1
I:min_log_rows set to default (3)
I:background_image=/sdcard/clockworkmod/custom_res/galaxy.png
I:setting up /data/media(/0) for /sdcard/clockworkmod/custom_res/galaxy.png.
I:using /data/media/0 for /sdcard
I:setting up /data/media(/0) for /sdcard/clockworkmod/custom_res/galaxy.png.
I:using /data/media/0 for /sdcard
I:custom backround /sdcard/clockworkmod/custom_res/galaxy.png loaded!
I:show_background_icon set to default (false)
I:show_battery set to default (true)
I:show_clock set to default (true)
I:menu_text_color set to default (8)
I:menu_background_color set to default (1)
I:menu_highlight_color set to default (7)
I:normal_text_color set to default (0)
I:menu_separator_color set to default (6)
I:header_text_color set to default (8)
I:batt_clock_color set to default (2)
I:menu_background_transparency set to default (102)
I:menu_highlight_transparency set to default (102)
I:menu_separator_transparency set to default (102)
I:show_menu_separation set to default (true)
I:dim_timeout=300
I:blank_timeout=1800
I:scroll_sensitivity=48
I:touch_accuracy set to default (7)
I:touch_to_validate=double_tap
I:enable_vibrator set to default (true)
I:boardEnableKeyRepeat set to default (true)
I:wait_after_install=0
I:slide_left_action set to default (5)
I:slide_right_action set to default (3)
I:double_tap_action set to default (2)
I:press_lift_action set to default (4)
I:press_move_action set to default (1)
I:t_zone=-8
I:t_zone_offset set to default (0)
I:use_dst_time=1
I:Current time: 2014-05-08 17:34:07 (UTC -8:00) DST
I:use_qcom_time_daemon set to default (0)
I:use_qcom_time_offset set to default (0)
Command: "/sbin/recovery"

af.resampler.quality=255
hw.trueMirrorSupported=1
ro.cm.device=moto_msm8960dt
ro.cm.display.version=11-20140507-UNOFFICIAL-moto_msm8960dt
ro.cm.version=11-20140507-UNOFFICIAL-moto_msm8960dt
ro.qc.sdk.audio.ssr=false
ro.qc.sdk.audio.fluencetype=none
ro.qc.sdk.camera.facialproc=true
ro.qc.sdk.sensors.gestures=false
ro.qc.sdk.gestures.camera=false
ro.sf.lcd_density=320
ro.com.google.clientidbase=android-motorola
ro.com.google.clientidbase.am=android-verizon
ro.com.google.clientidbase.ms=android-verizon
ro.com.google.clientidbase.yt=android-verizon
ro.com.android.dateformat=MM-dd-yyyy
ro.com.android.dataroaming=false
ro.com.android.wifi-watchlist=GoogleGuest
ro.cwm.forbid_format=/fsg,/firmware,/persist,/modem,/boot
ro.gsm.data_retry_config=default_randomization=2000,max_retries=infinite,1000,1000,80000,125000,485000,905000
ro.gsm.2nd_data_retry_config=max_retries=1,15000
ro.ksm.default=1
ro.mot.vr_source_dsp=1
ro.mot.ignore_csim_appid=true
ro.ril.transmitpower=true
ro.url.legal=http://www.google.com/intl/%s/mobile/android/basic/phone-legal.html
ro.url.legal.android_privacy=http://www.google.com/intl/%s/mobile/android/basic/privacy.html
ro.usb.bpt=0x2e28
ro.usb.mtp=0x2e62
ro.usb.ptp=0x2e64
ro.usb.bpteth=0x2e2a
ro.usb.bpt_adb=0x2e29
ro.usb.mtp_adb=0x2e63
ro.usb.ptp_adb=0x2e65
ro.usb.bpteth_adb=0x2e2b
ro.boot.cid=0x0
ro.boot.emmc=true
ro.boot.mode=normal
ro.boot.hwrev=0x8300
ro.boot.radio=0x2
ro.boot.device=ghost
ro.boot.carrier=vzw
ro.boot.modelno="Moto
ro.boot.baseband=msm
ro.boot.hardware=qcom
ro.boot.serialno=T062005KDG
ro.boot.bootloader=0x30B4
ro.boot.write_protect=0
ro.boot.secure_hardware=1
ro.cdma.home.operator.alpha=Verizon
ro.cdma.home.operator.isnan=1
ro.cdma.home.operator.numeric=310004
ro.cdma.nbpcd=1
ro.cdma.homesystem=64,65,76,77,78,79,80,81,82,83
ro.cdma.otaspnumschema=SELC,1,80,99
ro.cdma.data_retry_config=max_retries=infinite,0,0,10000,10000,100000,10000,10000,10000,10000,140000,540000,960000
ro.emmc=0
ro.wifi.channels=
ro.allow.mock.location=0
ro.board.platform=msm8960
ro.build.id=KVT49L
ro.build.date=Wed May 7 13:15:42 PDT 2014
ro.build.date.utc=0
ro.build.host=malingi
ro.build.tags=test-keys
ro.build.type=userdebug
ro.build.user=mstein
ro.build.display.id=cm_moto_msm8960dt-userdebug 4.4.2 KVT49L c76632ec6e test-keys
ro.build.product=moto_msm8960dt
ro.build.selinux=1
ro.build.version.sdk=19
ro.build.version.release=4.4.2
ro.build.version.codename=REL
ro.build.version.incremental=c76632ec6e
ro.build.description=ghost_verizon-user 4.4 13.11.1Q2.X-69-3 5 release-keys
ro.build.fingerprint=motorola/ghost_verizon/ghost:4.4/13.11.1Q2.X-69-3/5:user/release-keys
ro.build.characteristics=default
ro.modem.no_wdog_chk=1
ro.config.svdo=true
ro.config.ringtone=Orion.ogg
ro.config.alarm_alert=Hassium.ogg
ro.config.vc_call_vol_steps=7
ro.config.notification_sound=Argon.ogg
ro.crypto.fuse_sdcard=true
ro.secure=1
ro.vendor.extension_library=/system/lib/libqc-opt.so
ro.carrier=unknown
ro.cmlegal.url=http://www.cyanogenmod.org/docs/privacy
ro.product.cpu.abi=armeabi-v7a
ro.product.cpu.abi2=armeabi
ro.product.name=cm_moto_msm8960dt
ro.product.board=MSM8960
ro.product.brand=motorola
ro.product.model=Moto X
ro.product.device=ghost_verizon
ro.product.locale.region=US
ro.product.locale.language=en
ro.product.manufacturer=motorola
ro.baseband=msm
ro.bootmode=normal
ro.hardware=qcom
ro.opengles.version=196608
ro.qualcomm.bt.hci_transport=smd
ro.qualcomm.bluetooth.sap=true
ro.revision=33536
ro.serialno=T062005KDG
ro.bluetooth.hfp.ver=1.6
ro.bluetooth.remote.autoconnect=true
ro.bluetooth.request.master=true
ro.telephony.default_network=10
ro.telephony.gsm-routes-us-smsc=1
ro.bootloader=0x30B4
ro.debuggable=1
ro.modversion=11-20140507-UNOFFICIAL-moto_msm8960dt
ro.rommanager.developerid=cyanogenmod
ro.factorytest=0
ro.setupwizard.enterprise_mode=1
ro.use_data_netmgrd=true
com.qc.hardware=true
lpa.decode=true
mmp.enable.3g2=true
net.bt.name=Android
net.change=net.bt.name
ril.subscription.types=NV,RUIM
init.svc.adbd=running
init.svc.vold=running
init.svc.healthd=running
init.svc.ueventd=running
init.svc.recovery=running
init.svc.setup_adbd=stopped
qcom.hw.aac.encoder=true
rild.libargs=-d /dev/smd0
rild.libpath=/system/lib/libril-qc-qmi-1.so
debug.sf.hw=1
debug.egl.hw=1
debug.mdpcomp.logs=0
debug.enabletr=0
debug.composition.type=dyn
media.stagefright.enable-aac=true
media.stagefright.enable-qcp=true
media.stagefright.enable-http=true
media.stagefright.enable-scan=true
media.stagefright.enable-fma2dp=true
media.stagefright.enable-player=true
media.aac_51_output_enabled=true
dalvik.vm.heapsize=512m
dalvik.vm.lockprof.threshold=500
dalvik.vm.heapmaxfree=8m
dalvik.vm.heapminfree=512k
dalvik.vm.dexopt-flags=m=y
dalvik.vm.heapstartsize=8m
dalvik.vm.heapgrowthlimit=192m
dalvik.vm.stack-trace-file=/data/anr/traces.txt
dalvik.vm.heaptargetutilization=0.75
persist.gps.qmienabled=true
persist.hwc.mdpcomp.enable=true
persist.ril.max.crit.qmi.fails=4
persist.sys.qc.sub.rdump.on=1
persist.sys.qc.sub.rdump.max=20
persist.sys.qc.sub.rstrtlvl=3
persist.sys.dun.override=0
persist.sys.usb.config=adb
persist.sys.dalvik.vm.lib=libdvm.so
persist.sys.root_access=1
persist.rild.nitz_plmn=
persist.rild.nitz_long_ons_0=
persist.rild.nitz_long_ons_1=
persist.rild.nitz_long_ons_2=
persist.rild.nitz_long_ons_3=
persist.rild.nitz_short_ons_0=
persist.rild.nitz_short_ons_1=
persist.rild.nitz_short_ons_2=
persist.rild.nitz_short_ons_3=
persist.audio.vr.enable=false
persist.audio.fluence.mode=endfire
persist.audio.handset.mic=digital
persist.audio.lowlatency.rec=false
persist.radio.eons.enabled=1
persist.radio.call_type=1
persist.radio.vrte_logic=2
persist.radio.dfr_mode_set=1
persist.radio.mode_pref_nv10=1
persist.radio.skip_data_check=1
persist.radio.apm_sim_not_pwdn=1
persist.radio.no_wait_for_card=1
persist.radio.0x9e_not_callname=1
persist.rmnet.mux=disabled
persist.timed.enable=true
persist.fuse_sdcard=true
service.adb.root=1
keyguard.no_require_sim=true
recovery.perf.mode=0
telephony.lteOnCdmaDevice=1
telephony.rilV7NeedCDMALTEPhone=true

I:Checking for extendedcommand & OpenRecoveryScript...
I:Skipping execution of extendedcommand, file not found...
I:Skipping execution of OpenRecoveryScript, file not found...
I:setting up /data/media(/0) for /sdcard/clockworkmod/aromafm/aromafm.zip.
I:using /data/media/0 for /sdcard

-- Installing: /sdcard/clockworkmod/aromafm/aromafm.zip
Finding update package...
I:Update location: /data/media/0/clockworkmod/aromafm/aromafm.zip
Opening update package...
Installing update...
aroma/s: Initializing
aroma/s: Saving Arguments

AROMA Filemanager version 1.91
(c) 2013 by amarullz xda-developers

aroma/s: Open Archive
aroma/s: Initializing Resource
aroma/s: Opening Freetype
aroma/s: Graph Initialized
aroma/s: INDR Input Device: pmic8xxx_pwrkey (event0) - Class : 1
aroma/s: VKN : 0, CALIB : (0,0,0,0)
aroma/s: INDR Input Device: msm8960-snd-card Headset Jack (event4) - Class : 0
aroma/s: VKN : 0, CALIB : (0,0,0,0)
aroma/s: INDR Input Device: msm8960-snd-card Button Jack (event3) - Class : 1
aroma/s: VKN : 0, CALIB : (0,0,0,0)
aroma/s: INDR Input Device: gpio-keys (event5) - Class : 1
aroma/s: VKN : 0, CALIB : (0,0,0,0)
aroma/s: INDR Input Device: msp430sensorprocessor (event1) - Class : 1
aroma/s: VKN : 0, CALIB : (0,0,0,0)
aroma/s: INDR Input Device: synaptics_dsx_i2c (event2) - Class : 6
aroma/s: VKN : 0, CALIB : (0,719,0,1279)
aroma/s: Input Initialized
aroma/s: Mute Parent
aroma/s: Starting Interface
aroma/s: (1) Freetype fonts loaded as Font Family
aroma/s: (1) Freetype fonts loaded as Font Family
aroma/s: (1) Freetype fonts loaded as Font Family
Load Font: DroidSans.ttf - dir: assets/fonts/Droid Sans/
acfg_init_ex() - start
acfg_init_ex() - end
aroma/s: Automount All Partitions
aroma/s: Change Folder /
RESHOW PATH [/data/]
aroma/s: Change Folder /data/
RESHOW PATH [/]
aroma/s: Change Folder /
RESHOW PATH [/cache/]
aroma/s: Change Folder /cache/
RESHOW PATH [/cache/recovery/]
aroma/s: Change Folder /cache/recovery/
File [8]: last_log
RESHOW PATH [/cache/]
aroma/s: Change Folder /cache/
RESHOW PATH [/cache/]
Opening Terminal At : /cache/

::: END OF READER THREAD :::
aroma/s: Change Folder /cache/
RESHOW PATH [/cache/]
aroma/s: Unmounting /system
aroma/s: Close Graph Thread
aroma/s: Thread terminated
aroma/s: Starting Release
aroma/s: Font Released
aroma/s: Releasing Input Driveraroma/s: Input Released
aroma/s: Archive Released
aroma/s: Closing Freetype
aroma/s: Graph Released
aroma/s: Unmute Parent

AROMA Filemanager Finished...
aroma/s: Cleanup Temporary
aroma/s: Closing Recovery Pipe
aroma/s: Exit Status: 0 - Normal

Install from sdcard complete.
I:ro.modversion set to default (noname)
I:ro.romversion set to default (noname)
I:ro.build.display.id=Eclipse-v3.2.1
I:setting up /data/media(/0) for /sdcard/clockworkmod/.default_backup_format.
I:using /data/media/0 for /sdcard
I:setting up /data/media(/0) for /sdcard/clockworkmod/backup/2014-05-08.17.41.46_Eclipse-v3.2.1.
I:using /data/media/0 for /sdcard
I:Checking needed space for backup '/sdcard/clockworkmod/backup/2014-05-08.17.41.46_Eclipse-v3.2.1'
I:found device mmcblk link: '/dev/block/platform/msm_sdcc.1/by-name/recovery' -> '/dev/block/mmcblk0p34'
I:/recovery backup size (/proc)=10Mb
I:found device mmcblk link: '/dev/block/platform/msm_sdcc.1/by-name/boot' -> '/dev/block/mmcblk0p33'
I:/boot backup size (/proc)=10Mb
I:/system backup size (stat)=847Mb
I:/cache backup size (stat)=17Mb
I:/data: tot size=26957Mb, free=14969Mb, backup size=2079Mb, used=10586Mb, media=8507Mb

>> Free space: 14969Mb (55%)
>> Needed space: 2963Mb
mkdir: can't create directory '/sdcard/clockworkmod/backup/2014-05-08.17.41.46_Eclipse-v3.2.1': Permission denied

>> Backing up /boot...
Backing up boot image...
E:Error while backing up boot image!
Rebooting...
I:setting up /data/media(/0) for /sdcard/clockworkmod/.recovery_version.
I:using /data/media/0 for /sdcard
I:ro.build.version.sdk=19

Thanks

Edit 2: Addendum to addendum ...

Ah damn, where's my brain? I forgot to mention another weird thing where in the log I supplied here, at some point in the start, it doesn't find (or at least says /etc/extra.fstab not found), but while I was in there, I looked, and /etc/extra.fstab was there along with the other usual /etc/ files. So there's a few oddities. All I really had in the /etc/extra.fstab was 2 lines, one for the f2fs fs mount, a slightly simpler f2fs type mount without the final option of (=-16385) (or whatever that was), and the last line was for a /dev/sda1 USB dev. Not that it matters, since my build of this recovery couldn't find the extra fstab anyway.