#!/bin/bash year="" table="" if(($#==2)) then year=$1 table=$2 else year=2025 table=alg_recsys_feature_behavior_profile fi set -x export SPARK_HOME=/opt/apps/SPARK2/spark-2.4.8-hadoop3.2-1.0.8 export PATH=$SPARK_HOME/bin:$PATH export HADOOP_CONF_DIR=/etc/taihao-apps/hadoop-conf export JAVA_HOME=/usr/lib/jvm/java-1.8.0 # params suffix="y,8,4,0,e,a,c,k,o,w,g,s,u,q,i,m" savePath=/dw/recommend/model/user_profile/data/ # 1 生产原始数据 echo "$(date +%Y-%m-%d_%H-%M-%S)----------step1------------开始根据${table}生产原始数据" /opt/apps/SPARK2/spark-2.4.8-hadoop3.2-1.0.8/bin/spark-class2 org.apache.spark.deploy.SparkSubmit \ --class com.aliyun.odps.spark.examples.makedata_recsys_r_rate.makedata_profile_20251114 \ --master yarn --driver-memory 4G --executor-memory 6G --executor-cores 1 --num-executors 16 \ --conf spark.yarn.executor.memoryoverhead=2048 \ /mnt/disk1/jch/recommend-emr-dataprocess/target/spark-examples-1.0.0-SNAPSHOT-jar-with-dependencies.jar \ table:${table} tablePart:48 \ year:${year} \ suffix:${suffix} \ repartition:32 \ savePath:${savePath} \