Project

General

Profile

[solved] install new system from recovery after installing Replicant 6

Added by Fil Lupin about 6 years ago

Hi,
I finished installing Replicant 6 on a GT-I9100 (Galaxy S2) after encountering an sdcard issue (see https://redmine.replicant.us/boards/3/topics/14331).

However, when i try to install another system (for instance, replicant 4.2), it is impossible to install a new zip package once into recovery mode, either through "adb sideload" or "install from zip":

  • command "adb sideload" crashed with
    $> adb sideload replicant-4.2-i9100.zip 
    loading: 'replicant-4.2-i9100.zip'
    * failed to write data 'protocol fault (couldn't read status): Success' *
    
  • "install from zip" does not work:
    • when "choose zip from internal sdcard" :
      E:Can't mount /emmc
      
    • when "choose zip from sdcard" :
      E:Can't mount /sdcard
      

Logcat then contains:

Sideload started...
Now send the package you want to apply
to the device with "adb sideload <filename>"...

Restarting adbd...
status 0
No package received
Starting to open usb_init()
unix_open to usb_init(): -1
sideload_service  invoked
failed to create /tmp/update.zip
Restarting adbd...
I:sideload process finished
status 0
I:sideload thread finished
No package received.
I:Can't partition non-vfat: auto
I:Can't format unknown volume: /external_sd
I:Can't partition non-vfat: auto

When I installed package replicant-6.0-i9100.zip from zip and from adb sideload, both worked.

Once installing back Replicant 6, I can access /sdcard:

  • using the file manager, I got 2 default bookmarks:
    • sdcard0 (/storage/O4C5-F5A0)
    • Secure storage (/storage/O4C5-F5A0/storage/Secure
  • if I read from "adb shell" than "ls -la /storage", I got the following output:
root@i9100:/ # ls -la /storage/                                                
total 64
drwxr-xr-x  4 root root         80 2018-01-04 17:26 .
drwxr-xr-x 17 root root          0 2018-01-04 17:23 ..
drwxrwx--x  1 root sdcard_rw 32768 1970-01-01 01:00 04C5-F5A0
drwxr-xr-x  2 root root         60 2018-01-04 17:23 self

I do not remember seing this 04C5-F5A0 directory (it seems to me it was sdcard0/ or Sdcard0/ ). Could someone confirm this? Should I rename it?

Here are some other information:

  • Recently, I repaired my sdcard from being corrupted (https://redmine.replicant.us/boards/3/topics/14331), it is perhaps linked.
  • output of df :
    root@i9100:/storage # df -h
    Filesystem                    Size  Used Avail Use% Mounted on
    tmpfs                         393M   72K  393M   1% /dev
    none                          393M  8.0K  393M   1% /sys/fs/cgroup
    tmpfs                         393M     0  393M   0% /mnt
    /dev/block/mmcblk0p9          504M  453M   51M  90% /system
    /dev/block/mmcblk0p7           98M  4.2M   94M   5% /cache
    /dev/block/mmcblk0p1           20M  8.1M   12M  42% /efs
    /dev/block/mmcblk0p10         1.9G  281M  1.6G  14% /data
    /dev/block/mmcblk0p12         504M   96M  408M  20% /preload
    tmpfs                         393M     0  393M   0% /storage
    /dev/block/vold/public:179_11  12G  427M   11G   4% /mnt/media_rw/04C5-F5A0
    /dev/block/vold/public:179_11  12G  427M   11G   4% /mnt/secure/asec
    /dev/fuse                      12G  427M   11G   4% /mnt/runtime/default/04C5-F5A0
    /dev/fuse                      12G  427M   11G   4% /storage/04C5-F5A0
    /dev/fuse                      12G  427M   11G   4% /mnt/runtime/read/04C5-F5A0
    /dev/fuse                      12G  427M   11G   4% /mnt/runtime/write/04C5-F5A0
    
  • mount:
    1|root@i9100:/ # mount
    rootfs on / type rootfs (ro,seclabel,relatime)
    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)
    /sys/kernel/debug on /sys/kernel/debug type debugfs (rw,seclabel,relatime)
    none on /acct type cgroup (rw,relatime,cpuacct)
    none on /sys/fs/cgroup type tmpfs (rw,seclabel,relatime,mode=750,gid=1000)
    none on /sys/fs/cgroup/memory type cgroup (rw,relatime,memory)
    tmpfs on /mnt type tmpfs (rw,seclabel,relatime,mode=755,gid=1000)
    none on /dev/memcg type cgroup (rw,relatime,memory)
    none on /dev/cpuctl type cgroup (rw,relatime,cpu)
    /dev/block/mmcblk0p9 on /system type ext4 (ro,seclabel,noatime,user_xattr,barrier=1,data=ordered)
    /dev/block/mmcblk0p7 on /cache type ext4 (rw,seclabel,nosuid,nodev,noatime,errors=panic,user_xattr,barrier=1,journal_async_commit,data=ordered)
    /dev/block/mmcblk0p1 on /efs type ext4 (rw,seclabel,nosuid,nodev,noatime,user_xattr,barrier=1,journal_async_commit,data=ordered)
    /dev/block/mmcblk0p10 on /data type ext4 (rw,seclabel,nosuid,nodev,noatime,errors=panic,user_xattr,barrier=1,journal_async_commit,data=ordered,noauto_da_alloc)
    /dev/block/mmcblk0p12 on /preload type ext4 (rw,seclabel,nosuid,nodev,noatime,user_xattr,barrier=1,journal_async_commit,data=ordered)
    tmpfs on /storage type tmpfs (rw,seclabel,relatime,mode=755,gid=1000)
    /dev/block/vold/public:179_11 on /mnt/media_rw/04C5-F5A0 type fuseblk (rw,dirsync,nosuid,nodev,noexec,noatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096)
    /dev/block/vold/public:179_11 on /mnt/secure/asec type fuseblk (rw,dirsync,nosuid,nodev,noexec,noatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096)
    /dev/fuse on /mnt/runtime/default/04C5-F5A0 type fuse (rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other)
    /dev/fuse on /storage/04C5-F5A0 type fuse (rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other)
    /dev/fuse on /mnt/runtime/read/04C5-F5A0 type fuse (rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other)
    /dev/fuse on /mnt/runtime/write/04C5-F5A0 type fuse (rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other)
    
  • $EXTERNAL_STORAGE:
    shell@i9100:/ $ echo $EXTERNAL_STORAGE
    /sdcard
    
  • I put my replicant-4.2-i9100.zip file into /sdcard. This directory links to /storage/self/primary/ and is the same that /storage/04C5-F5A0:
    1|root@i9100:/ # ls -la /sdcard/                                                                                                                               
    ls: /sdcard//.android_secure: Permission denied
    total 869888
    drwxrwx--x 1 root sdcard_rw     32768 1970-01-01 01:00 .
    drwxr-xr-x 4 root root             80 2018-01-04 18:04 ..
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 Alarms
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 Android
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 DCIM
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 Download
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 Movies
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 Music
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 Notifications
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 Pictures
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 Podcasts
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:23 Ringtones
    -rwxrwx--x 1 root sdcard_rw 166172654 2018-01-04 11:14 replicant-4.2-i9100.zip
    -rwxrwx--x 1 root sdcard_rw 278763788 2018-01-04 11:15 replicant-6.0-i9100.zip
    drwxrwx--x 1 root sdcard_rw     32768 2018-01-04 11:29 storage
    

How could I get back access to /emmc and /sdcard a new system on my phone?

Anyone who could send me the normal output in its phone please? Espacialy this is very easy to do and would help me a lot.

Thank you.


Replies (8)

RE: install new system from recovery after installing Replicant 6 - Added by Fil Lupin about 6 years ago

I reformated my sdcard following these steps:
- starting into recovery mode
- in "advanced" menu, mount /system
- in a terminal, "adb shell" and then "mkfs.f2fs -l f2fs /dev/block/vold/public\:179_11"

Then, after restarting in normal mode, I can access from my computer to "Android" to sdcard, and an icon appears so it seems a more normal behaviour.
However, I still can not access to sdcard in recevery miode...

I found this doc: https://source.android.com/devices/storage/config-example
It gives configuration examples for Android system.
However, it is not cleat that GT-I9100 has not been modified in comparison to these examples.

It would help me a lot if any user of a GT-I9100 (Galaxy S2) could help me by printing here the output of the following files to correct them if needed:
  • cat /fstab.smdk4210
  • cat /init.smdk4210.rc

These steps are very simple and do not modify anything, anyone without technical skill can do this.
If you are a GT-I9100 Replicant 6 user, could you print here these output please?

edit: here is the content of these two files for my phone:

  • init.smdk4210rc :
    1|root@i9100:/ # cat init.smdk4210.rc
    import init.smdk4210.usb.rc
    
    on init
        mkdir /efs 0771 radio system
        mkdir /preload 0771 system system
        mkdir /mnt 0775 root system
        mkdir /mnt/.lfs 0755 root root
    
        # for backwards compatibility
        symlink /sdcard /mnt/sdcard
        symlink /sdcard /storage/sdcard
    
    # Disable CFQ slice idle delay
        write /sys/block/mmcblk0/queue/iosched/slice_idle 0
    
    on fs
        mount_all /fstab.smdk4210
        swapon_all /fstab.smdk4210
    
        mkdir /efs/bluetooth
        mkdir /efs/wifi
        chown radio system /efs/bluetooth
        chown radio system /efs/wifi
        chmod 0775 /efs/bluetooth
        chmod 0775 /efs/wifi
    
        mkdir /data/misc/vpn/profiles 0770 system system
        mkdir /data/misc/radio 0775 radio system
        mkdir /data/radio 0770 radio radio
        chmod 0770 /data/misc/wifi 
    
    on charger
    
    # CPU Frequency Governor
        write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor powersave
    
    # EHCI runtime enable for LPA
        write /sys/devices/platform/s5p-ehci/power/control auto
    
    on post-fs-data
    # insmod kernel modules
        insmod /system/lib/modules/j4fs.ko
        insmod /system/lib/modules/Si4709_driver.ko
    
    # mount param.lfs
        mount j4fs /dev/block/mmcblk0p4 /mnt/.lfs
    
    # MDNS
        socket mdns stream 0660 root system
    
        # give system access to wpa_supplicant.conf for backup and restore
        mkdir /data/misc/wifi 0770 wifi wifi
        chmod 0770 /data/misc/wifi
        chmod 0660 /data/misc/wifi/wpa_supplicant.conf
        mkdir /data/misc/wifi/sockets 0770 wifi wifi
        mkdir /data/misc/dhcp 0770 dhcp dhcp
        chown dhcp dhcp /data/misc/dhcp
        chown wifi root /dev/rfkill
    
    #DRM directory creation
        mkdir /system/etc/security/.drm 0775
        chown root root /system/etc/security/.drm
        chmod 0775 /system/etc/security/.drm
    
        # Added for Playready DRM Support
        mkdir /data/data/.drm 0775
        chown drm system /data/data/.drm
        chmod 0775 /data/data/.drm
        mkdir /data/data/.drm/.playready 0775
        chown drm system /data/data/.drm/.playready
        chmod 0775 /data/data/.drm/.playready
    
        #Added drm folder to copy drm plugins
        mkdir /system/lib/drm 0775
        chown root root /system/lib/drm
        chmod 0775 /system/lib/drm
    
        # DivX DRM
        mkdir /efs/.files 0775
        mkdir /efs/.files/.dx1 0775
        mkdir /efs/.files/.dm33 0775
        mkdir /efs/.files/.mp301 0775
        chown media system /efs/.files/.dx1
        chown media system /efs/.files/.dm33
        chown media system /efs/.files/.mp301
        chmod 0775 /efs/.files/.dx1
        chmod 0775 /efs/.files/.dm33
        chmod 0775 /efs/.files/.mp301
    
    # SELinux restore context for efs files
        restorecon_recursive /efs
    
    # MTP Device permission.
        chmod 0660 /dev/mtp_usb
        chown system mtp /dev/mtp_usb
    
    # terminal mode
        chmod 0660 /sys/class/android_usb/android0/terminal_version
        chown system system /sys/class/android_usb/android0/terminal_version
    
    # NFC
        setprop ro.nfc.port "I2C" 
        chmod 0600 /dev/pn544
        chown nfc nfc /dev/pn544
    
    # setup for alsa snd device
        chmod 0770 /dev/snd/pcmC0D0c
        chmod 0770 /dev/snd/pcmC0D0p
        chmod 0770 /dev/snd/controlC0
        chmod 0770 /dev/snd/timer
        chmod 0770 /dev/snd/hwC0D0
    
        # create log system
        mkdir /data/log 0775 system log
        chown system log /data/log
    
        chmod 0775 /data/log
        chmod 0775 /data/anr
    
    #panorama directory creation
        mkdir /data/pxtmpdir 0775
        chown system system /data/pxtmpdir
        chmod 0775 /data/pxtmpdir
    
        # permission for HDMI audio path
        chown media audio /sys/class/hdmi_audio/hdmi_audio/hdmi_audio_set_ext
    
    # Permissions for gpio_keys.
        chown system radio /sys/class/sec/sec_key/wakeup_keys 
        write /sys/class/sec/sec_key/wakeup_keys  102,116
    
    # Add permission for ATM. 2010.03.20
        chown system radio /sys/devices/platform/i2c-gpio.9/i2c-9/9-0036/power_supply/fuelgauge/fg_read_soc
        chown system radio /sys/devices/platform/i2c-gpio.9/i2c-9/9-0036/power_supply/fuelgauge/fg_reset_soc
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_lpm_state
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/fg_psoc
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/system_rev
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_current_adc
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_test_value
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_temp_adc_spec
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_temp_check
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_full_check
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_type
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/mp3
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/video
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_lp_charging
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/charging_source
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/charging_enabled
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_temp_adc_avg
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_temp_adc
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_temp
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_vfocv
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_soc
        chown system radio /sys/devices/platform/sec-battery/power_supply/battery/batt_vol
    
        chown system system /sys/class/backlight/panel/brightness
        chown system system /sys/class/power_supply/battery/temp
    
    # Permissions for input devices
        chown system radio /sys/devices/virtual/sec/sec_key/sec_key_pressed
    
        chown system radio /sys/devices/virtual/sec/sec_touchkey/force_disable
        chown system radio /sys/devices/virtual/sec/sec_touchkey/recommended_version
        chown system radio /sys/devices/virtual/sec/sec_touchkey/touch_sensitivity
        chown system radio /sys/devices/virtual/sec/sec_touchkey/brightness
        chown system radio /sys/devices/virtual/sec/sec_touchkey/touchkey_brightness
        chown system radio /sys/devices/virtual/sec/sec_touchkey/touchkey_back
        chown system radio /sys/devices/virtual/sec/sec_touchkey/touchkey_menu
        chown system radio /sys/devices/virtual/sec/sec_touchkey/touchkey_firm_version_panel
        chown system radio /sys/devices/virtual/sec/sec_touchkey/touchkey_firm_version_phone
        chown system radio /sys/devices/virtual/sec/sec_touchkey/touchkey_firm_update_status
        chown system radio /sys/devices/virtual/sec/sec_touchkey/touchkey_firm_update
        chown system radio /sys/devices/virtual/sec/sec_touchkey/updated_version
        chown system radio /sys/devices/virtual/sec/sec_touchkey/timeout
    
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_firm_version
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_threshould
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_all_delta
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_all_refer
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_delta4
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_refer4
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_delta3
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_refer3
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_delta2
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_refer2
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_delta1
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_refer1
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_delta0
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_refer0
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/disp_all_deltadata
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/disp_all_refdata
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_module_off
        chown system radio /sys/devices/virtual/sec/tsp_noise_test/set_module_on
    
        chown system radio /sys/devices/virtual/sec/sec_touchscreen/tsp_firm_version_panel
        chown system radio /sys/devices/virtual/sec/sec_touchscreen/tsp_firm_version_phone
        chown system radio /sys/devices/virtual/sec/sec_touchscreen/tsp_firm_update_status 
        chown system radio /sys/devices/virtual/sec/sec_touchscreen/tsp_firm_update 
        chown system radio /sys/devices/virtual/sec/sec_touchscreen/tsp_threshold
        chown system radio /sys/devices/virtual/sec/sec_touchscreen/tsp_config_version
        chown system radio /sys/devices/virtual/sec/sec_touchscreen/tsp_touchtype
    
    # Permissions for bluetooth
        setprop ro.bt.bdaddr_path "/efs/bluetooth/bt_addr" 
        chown bluetooth bluetooth ro.bt.bdaddr_path
        chown bluetooth bluetooth /dev/ttySAC0
        chmod 0600 /dev/ttySAC0
        chmod 0660 /sys/class/rfkill/rfkill0/state
        chown bluetooth bluetooth /sys/class/rfkill/rfkill0/state
        chown bluetooth bluetooth /sys/class/rfkill/rfkill0/type
    
    # Vibetonz
        chmod 0660 /dev/tspdrv
        chown root shell /dev/tspdrv
        chmod 0660 /sys/class/timed_output/vibrator/pwm_value
        chown system system /sys/class/timed_output/vibrator/pwm_value
    
    # Permissions for LCD
        chown system radio /sys/class/lcd/panel/lcd_power
        chown system radio /sys/class/lcd/panel/lcd_type
        chown system media_rw /sys/class/lcd/panel/gamma_mode
        chown system media_rw /sys/class/lcd/panel/power_reduce
        chown system system /sys/class/backlight/panel/auto_brightness
    
    # Permissions for mDNIe
        chown system media_rw /sys/class/mdnie/mdnie/mode
        chown system media_rw /sys/class/mdnie/mdnie/outdoor
        chown system media_rw /sys/class/mdnie/mdnie/scenario
        chown system media_rw /sys/class/mdnie/mdnie/negative
        write /sys/class/mdnie/mdnie/scenario 0
        write /sys/class/mdnie/mdnie/mode 1
    
    # Permissions for uart_sel and usb_sel
        chown system radio /sys/class/sec/switch/uart_sel/value
        chown system radio /sys/class/sec/switch/usb_sel
        chown system radio /sys/class/sec/switch/audio_path
        chown system radio /sys/class/sec/switch/otg_test
        chown system radio /sys/class/sec/switch/adc_debounce_time
        chown system radio /sys/class/sec/switch/status
        chown system radio /sys/class/sec/switch/adc
        chown system radio /mnt/.lfs/sw_sel
    
    # Permissions for OTG Test
        chown system radio /sys/class/host_notify/usb_otg/booster
        chmod 0664 /sys/class/host_notify/usb_otg/booster
    
    # Permission for radio
        chown system radio /sys/devices/platform/s5p-ehci/ehci_power
        chown system radio /sys/devices/platform/s5p-ehci/ehci_runtime
        chown system radio /sys/devices/virtual/misc/multipdp/waketime    
    
    # for datarouter
        chown system system /dev/dun
        chown system system /dev/ttyGS0
        chown system system /dev/ttyGS1
        chown system system /dev/ttyGS2
        chown system system /dev/ttyGS3
    
    # DVFS - cpufreq ondemand
        write /sys/devices/system/cpu/cpufreq/ondemand/down_differential 5
        write /sys/devices/system/cpu/cpufreq/ondemand/up_threshold 85
    
    #panorama directory creation
        mkdir /data/pxtmpdir 0775
        chown system system /data/pxtmpdir
        chmod 0775 /data/pxtmpdir
    
    # backlight permissions
        chown system system /sys/class/backlight/pwm-backlight/brightness
        chmod 0660 /sys/class/backlight/pwm-backlight/brightness
        chown radio system /sys/devices/virtual/misc/melfas_touchkey/brightness
        chmod 0660 /sys/devices/virtual/misc/melfas_touchkey/brightness
    
    # Permissions for dvfs lock
        chown system system /sys/power/cpufreq_max_limit
        chown system system /sys/power/cpufreq_min_limit
        chmod 0660 /sys/power/cpufreq_max_limit
        chmod 0660 /sys/power/cpufreq_min_limit
    
        chown system system /sys/power/gpu_lock
        chmod 0660 /sys/power/gpu_lock
    
    # Permisions for sensors
        chown radio system /sys/devices/virtual/K3G_GYRO-dev/k3g/gyro_selftest
        chown radio system /sys/devices/virtual/K3G_GYRO-dev/k3g/gyro_get_temp
        chown radio system /sys/devices/virtual/K3G_GYRO-dev/k3g/gyro_power_on
        chown radio system /sys/devices/virtual/accelerometer/accelerometer/acc_file
        chown radio system /sys/devices/virtual/sec/gsensorcal/calibration
    
    # for device encryption
        setprop vold.post_fs_data_done 1
    
    on boot
        mount debugfs /sys/kernel/debug /sys/kernel/debug
        setprop wifi.interface wlan0
    
    # permissions for NFC
        setprop ro.nfc.port "I2C" 
        chmod 0600 /dev/pn544
        chown nfc nfc /dev/pn544
    
    # fake some battery state
        setprop status.battery.state Slow
        setprop status.battery.level 5
        setprop status.battery.level_raw  50
        setprop status.battery.level_scale 9
    
    # increase read-ahead value to 256 kb
        write /sys/block/mmcblk0/queue/read_ahead_kb 256
    
    service charger /sbin/healthd -c
        class charger
        critical
        seclabel u:r:healthd:s0
    
    service p2p_supplicant /system/bin/wpa_supplicant \
        -iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf \
        -I/system/etc/wifi/wpa_supplicant_overlay.conf -N \
        -ip2p0 -Dnl80211 -c/data/misc/wifi/p2p_supplicant.conf \
        -I/system/etc/wifi/p2p_supplicant_overlay.conf \
        -puse_p2p_group_interface=1 \
        -e/data/misc/wifi/entropy.bin -g@android:wpa_wlan0
        #   we will start as root and wpa_supplicant will switch to user wifi
        #   after setting up the capabilities required for WEXT
        #   user wifi
        #   group wifi inet keystore
        class main
        socket wpa_wlan0 dgram 660 wifi wifi
        disabled
        oneshot
    
    service wpa_supplicant /system/bin/wpa_supplicant \
        -iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf \
        -I/system/etc/wifi/wpa_supplicant_overlay.conf \
        -e/data/misc/wifi/entropy.bin -g@android:wpa_wlan0
        #   we will start as root and wpa_supplicant will switch to user wifi
        #   after setting up the capabilities required for WEXT
        #   user wifi
        #   group wifi inet keystore
        class main
        socket wpa_wlan0 dgram 660 wifi wifi
        disabled
        oneshot
    
    service dhcpcd_wlan0 /system/bin/dhcpcd -ABKL
        class main
        disabled
        oneshot
    
    service dhcpcd_p2p /system/bin/dhcpcd -aABKL
        class main
        disabled
        oneshot
    
    service dhcpcd_bt-pan /system/bin/dhcpcd -ABKL
        class main
        disabled
        oneshot
    
    service iprenew_wlan0 /system/bin/dhcpcd -n
        class main
        disabled
        oneshot
    
    service iprenew_p2p /system/bin/dhcpcd -n
        class main
        disabled
        oneshot
    
    service iprenew_bt-pan /system/bin/dhcpcd -n
        class main
        disabled
        oneshot
    
    service macloader /system/bin/macloader
        class main
        oneshot
    
  • /fstab.smdk421 :
    root@i9100:/ # cat /fstab.smdk421                                              
    # Android fstab file.
    #<src>                                      <mnt_point>             <type>    <mnt_flags and options>                                   <fs_mgr_flags>
    # The filesystem that contains the filesystem checker binary (typically /system) cannot
    # specify MF_CHECK, and must come before any filesystems that do specify MF_CHECK
    # data partition must be located at the bottom for supporting device encryption
    
    /dev/block/mmcblk0p9                        /system                 ext4      ro,noatime                                                wait
    /dev/block/mmcblk0p7                        /cache                  f2fs      noatime,nosuid,nodev,inline_data,inline_xattr,discard     wait
    /dev/block/mmcblk0p7                        /cache                  ext4      noatime,nosuid,nodev,journal_async_commit,errors=panic    wait,check_spo
    /dev/block/mmcblk0p1                        /efs                    ext4      noatime,nosuid,nodev,journal_async_commit,errors=panic    wait,check_spo
    /dev/block/mmcblk0p10                       /data                   f2fs      noatime,nosuid,nodev,inline_data,inline_xattr,discard     wait,encryptable=footer,length=-16384
    /dev/block/mmcblk0p10                       /data                   ext4      noatime,nosuid,nodev,noauto_da_alloc,journal_async_commit,errors=panic    wait,check_spo,encryptable=footer,length=-16384
    /dev/block/mmcblk0p12                       /preload                ext4      noatime,nosuid,nodev,journal_async_commit                 wait
    
    # vold-managed volumes ("block device" is actually a sysfs devpath)
    /devices/platform/dw_mmc/mmc_host/mmc0/mmc0*                  auto    auto    defaults        wait,voldmanaged=sdcard0:11,noemulatedsd,nonremovable
    /devices/platform/s3c-sdhci.2/mmc_host/mmc1*                  auto    auto    defaults        wait,voldmanaged=sdcard1:auto,encryptable=userdata
    /devices/platform/s3c_otghcd/usb*                             auto    auto    defaults        voldmanaged=usb:auto
    
    # recovery
    /dev/block/mmcblk0p5                        /boot                   emmc      defaults      recoveryonly
    /dev/block/mmcblk0p6                        /recovery               emmc      defaults      recoveryonly
    
    # zRAM
    /dev/block/zram0                            none                    swap      defaults      zramsize=268435456,zramstreams=2
    

RE: install new system from recovery after installing Replicant 6 - Added by Fil Lupin about 6 years ago

After thinking again to my issue, it seems this is due to interaction between recovery builded for Replicant 4.2 and recovery builded for Replicant 6.

Indeed, when sending with heimdall recovery builded for Replicant 6, I have no problem to install Replicant 6.
But when I send with heimdall the recovery builded for Replicant 4.2, I encounter this issue to mount /emmc and /sdcard.

It seems to me Paul would be the ideal interlocutor, am I wrong?

edit: on a suggestion of Jeremy Rand, I tested another USB cable just in case. Saldy, it did not solve the issue I encountered to install replicant 4.2.

RE: install new system from recovery after installing Replicant 6 - Added by Fil Bergamo about 6 years ago

Not something that I would recommend as a long-lived solution but, given your urgent need:
Have you tried flashing TWRP recovery?
It is usually capable of installing any kind of zip file on top of it, and it also has an option to skip signature verification.

As I said, it is all but a wise solution.. but if you're stuck with no phone, it's better than nothing.
I'm not even sure TWRP is totally free software, but you can scan through its code and licenses here: https://github.com/TeamWin/twrpme

RE: install new system from recovery after installing Replicant 6 - Added by Fil Lupin about 6 years ago

Thank you Fil Bergamo, I'll give a try with TWRP.

edit: for information, it seems TWRP source code is open source but the app itself does not seems so (https://github.com/TeamWin/twrpme/issues/24).

RE: install new system from recovery after installing Replicant 6 - Added by Fil Bergamo about 6 years ago

Fil Lupin wrote:

edit: for information, it seems TWRP source code is open source but the app itself does not seems so (https://github.com/TeamWin/twrpme/issues/24).

The app and the recovery image are completely different things, though. The one you need is just the recovery image.

RE: install new system from recovery after installing Replicant 6 - Added by Fil Lupin about 6 years ago

I installed TWRP, at first, I was stuck on the replicant logo but after a few tries, it succeeded.

When installing replicant 4.2 on my GT-i9100, I have no sdcard accessible. Since I had a similar issue formerly with replicant 6, it seems this is linked.
Here is a few data:

root@android:/ # echo $EXTERNAL_STORAGE
/storage/sdcard0
root@android:/ # cat fstab.smdk4210                                            
# Android fstab file.
#<src>                  <mnt_point>         <type>    <mnt_flags and options>                               <fs_mgr_flags>
# The filesystem that contains the filesystem checker binary (typically /system) cannot
# specify MF_CHECK, and must come before any filesystems that do specify MF_CHECK
# data partition must be located at the bottom for supporting device encryption

/dev/block/mmcblk0p9    /system             ext4      ro,noatime    wait
/dev/block/mmcblk0p7    /cache              ext4      noatime,nosuid,nodev,journal_async_commit,errors=panic    wait,check_spo
/dev/block/mmcblk0p1    /efs                ext4      noatime,nosuid,nodev,journal_async_commit,errors=panic    wait,check_spo
/dev/block/mmcblk0p10   /data               ext4      noatime,nosuid,nodev,discard,noauto_da_alloc,journal_async_commit,errors=panic    wait,check_spo,encryptable=/efs/metadata
/dev/block/mmcblk0p12   /preload            ext4      ro,nosuid,nodev,noatime    wait
root@android:/ # mount
rootfs / rootfs ro,relatime 0 0
tmpfs /dev tmpfs rw,nosuid,relatime,mode=755 0 0
devpts /dev/pts devpts rw,relatime,mode=600 0 0
proc /proc proc rw,relatime 0 0
sysfs /sys sysfs rw,relatime 0 0
none /acct cgroup rw,relatime,cpuacct 0 0
tmpfs /mnt/secure tmpfs rw,relatime,mode=700 0 0
tmpfs /mnt/asec tmpfs rw,relatime,mode=755,gid=1000 0 0
tmpfs /mnt/obb tmpfs rw,relatime,mode=755,gid=1000 0 0
tmpfs /mnt/fuse tmpfs rw,relatime,mode=775,gid=1000 0 0
none /dev/cpuctl cgroup rw,relatime,cpu 0 0
/dev/block/mmcblk0p9 /system ext4 ro,noatime,user_xattr,barrier=1,data=ordered 0 0
/dev/block/mmcblk0p7 /cache ext4 rw,nosuid,nodev,noatime,errors=panic,user_xattr,barrier=1,journal_async_commit,data=ordered 0 0
/dev/block/mmcblk0p1 /efs ext4 rw,nosuid,nodev,noatime,user_xattr,barrier=1,journal_async_commit,data=ordered 0 0
/dev/block/mmcblk0p10 /data ext4 rw,nosuid,nodev,noatime,errors=panic,user_xattr,barrier=1,journal_async_commit,data=ordered,noauto_da_alloc,discard 0 0
/dev/block/mmcblk0p12 /preload ext4 ro,nosuid,nodev,noatime,user_xattr,barrier=1,data=ordered 0 0
/sys/kernel/debug /sys/kernel/debug debugfs rw,relatime 0 0
1|root@android:/ # df
Filesystem               Size     Used     Free   Blksize
/dev                   395.5M    48K   395.5M   4096
/mnt/secure            395.5M     0K   395.5M   4096
/mnt/asec              395.5M     0K   395.5M   4096
/mnt/obb               395.5M     0K   395.5M   4096
/mnt/fuse              395.5M     0K   395.5M   4096
/system                503.9M   242.5M   261.4M   4096
/cache                  98.4M    54.9M    43.5M   4096
/efs                    19.7M     8.1M    11.5M   4096
/data                    2G   342M     1.6G   4096
/preload               503.9M    96.1M   407.8M   4096
root@android:/ # ls -la /dev/block/vold/                                       
brw------- root     root     179,   0 2018-01-16 00:17 179:0
brw------- root     root     179,   1 2018-01-16 00:17 179:1
brw------- root     root     179,   2 2018-01-16 00:17 179:2
brw------- root     root     179,   3 2018-01-16 00:17 179:3
brw------- root     root     179,   4 2018-01-16 00:17 179:4
brw------- root     root     179,   5 2018-01-16 00:17 179:5
brw------- root     root     179,   6 2018-01-16 00:17 179:6
brw------- root     root     179,   7 2018-01-16 00:17 179:7
brw------- root     root     259,   0 2018-01-16 00:17 259:0
brw------- root     root     259,   1 2018-01-16 00:17 259:1
brw------- root     root     259,   2 2018-01-16 00:17 259:2
brw------- root     root     259,   3 2018-01-16 00:17 259:3
brw------- root     root     259,   4 2018-01-16 00:17 259:4

So it confirms the sdcard is not visible... I know I should mount and format the sdcard but I do not know how to do this currently.
Does anyone know how to do this?
Thank you

RE: install new system from recovery after installing Replicant 6 - Added by Fil Lupin about 5 years ago

Note : my i9100 still suffers the same problem since 1 year. Sdcard can't be used.

Thinking about https://redmine.replicant.us/boards/3/topics/15109?r=15116#message-15116 I wonder if repartitioning my i9100 with partition available in the zip file could help seeing again the sdcard since no other solution has been proposed.

What do you think about this?

RE: install new system from recovery after installing Replicant 6 - Added by Fil Lupin almost 5 years ago

I install again an image of Replicant 4.2 to solve this issue, following the suggestion made by Gnutoo.

1. I tried to build a 4.2 image (https://redmine.replicant.us/boards/15/topics/15142), but without any success
2. then I decided to install a replicant 4.2 image

I now am able to access to sdcard.

Thank you Gnutoo for your suggestion. :)

    (1-8/8)